• NumXL shopping Cart
  •  
    NumXL for Microsoft Excel makes sense of time series analysis:

    • Build, validate, rank models, and forecast right in Excel
    • Keep the data, analysis and models linked together
    • Make and track changes instantly
    • Share your results by sending just one file

    >>Read More


    | Free Trial
  • Home
  • Products
  • Tips & Demos
  • Support
    • Documentation
    • Blog
    • FAQ
    • Library
    • Service Level Agreement
    • Thank you
    • Beta Program
    • Resources
  • About Us
  • Prices
  •  
     

    Have a Question?

    Phone: +1 (888) 427-9486
    +1 (312) 257-3777
    Contact Us

    Home >> Support >> Documentation >> NumXL >> Reference Manual >> Descriptive Stats >> LRVar

    LRVar

    Returns the long run variance using a Bartlett kernel with window size k.


    Syntax

    LRVar(X, k)

    X
    is the input data sample (a one dimensional array of cells (e.g. rows or columns)).

    k
    is the input Bartlett kernel window size. If omitted, the default value is the cubic root of the sample data size.


    Remarks


    1. The input time series data may include missing values (e.g. #N/A, #VALUE!, #NUM!, empty cell), but they will not be included in the calculations.
    2. The long-run variance is computed as follows:
      $ \sigma^2=\frac{1}{T}\sum_{t=k}^{T-k}\sum_{i=-k}^k w_i(x_t-\bar{x})(x_{t-i}-\bar{x})  $
      Where:

      • $ x_{t} \in X $ is a value from the input time series data
      • $ \bar{x} $ is the mean of the input time series data
      • The weight ($ w_i $) in Bartlett kernel is defined as follows:
        \[ w_i= 1- \frac{\left | i \right |}{k+1} \]
      • $ k $ is the input window size for the Bartlett kernel


    Examples


    Example 1:

    A B
    1 Date Data
    2 1/1/2008 #N/A
    3 1/2/2008 -1.28
    4 1/3/2008 0.24
    5 1/4/2008 1.28
    6 1/5/2008 1.20
    7 1/6/2008 1.73
    8 1/7/2008 -2.18
    9 1/8/2008 -0.23
    10 1/9/2008 1.10
    11 1/10/2008 -1.09
    12 1/11/2008 -0.69
    13 1/12/2008 -1.69
    14 1/13/2008 -1.85
    15 1/14/2008 -0.98
    16 1/15/2008 -0.77
    17 1/16/2008 -0.30
    18 1/17/2008 -1.28
    19 1/18/2008 0.24
    20 1/19/2008 1.28
    21 1/20/2008 1.20
    22 1/21/2008 1.73
    23 1/22/2008 -2.18
    24 1/23/2008 -0.23
    25 1/24/2008 1.10
    26 1/25/2008 -1.09
    27 1/26/2008 -0.69
    28 1/27/2008 -1.69
    29 1/28/2008 -1.85
    30 1/29/2008 -0.98

    Formula Description (Result)
    =LRVar($B$2:$B$30,3) Long-run variance (2.084)

    Files Examples



    References


    • Hamilton, J .D.; Time Series Analysis , Princeton University Press (1994), ISBN 0-691-04289-6
    • Tsay, Ruey S.; Analysis of Financial Time Series John Wiley & SONS. (2005), ISBN 0-471-690740

    Related Links

    • Wikipedia - Stochastic Volatility
    ‹ IQRupMAD ›

    Tips & Hints

    • Volatility 102

    • Download Sites - NumXL
    Try our full-featured product free for 14 days

    Download NumXL Free 30-day Trial

    Help desk

    Questions?
    Request a feature?
    Report an issue?

    » Go to your help desk «

    Or email us:
    support@numxl.com

    • NumXL 1.65 (HAMMOCK) Está Aquí!
      05/18/2017 - 21:31
    • NumXL 1.65 (HAMMOCK) is Here!
      05/18/2017 - 21:14
    • NumXL 1.64 (TURRET) is here
      12/25/2016 - 13:12

    ARIMA ARMA Forecast Getting Started goodness of fit LLF SARIMA scenario simulation statistical test tutorial user's guide
    more tags
     

    • Support
    • FAQ
    • Demos & Tutorials
    • Documentation
    • Help Desk

    • Resources
    • Order Help

    • About Spider
    • Contact Spider
    • Corporate Information
    • Legal Information
    • Partners

    Follow Us

    Contact | Glossary | Sitemap | Blog | Links
    © 2008-2019 Spider Financial | Disclaimer | Terms of Use | Privacy Policy | Trademarks & Copyrights