Transforming Independent Variables

<- Previous: setCVIndEqs
Next ->: The Estimation

The keyword function setIndVars installs the selected independent variables in the FANPAC global _fan_IndVars. Once this has been accomplished you can directly transform the variables in that matrix. Thus

    library fanpac;
    session amzn 'inCV model';
    setDataSet stocks;
    setSeries AMZN;

    setIndVars AMZNvol;

    _fan_IndVars = ln(_fan_IndVars);


    estimate run2 garch(1,1);

It is important that any such transformations take place after all calls to setSeries, setIndVars, and computeLogReturns or computePercentReturns. And transformations must not change the length of the data matrix stored in _fan_IndVars.

Generally, it would be safer and better to make any required transformations to the data in a separate command file in which the new dataset for analysis is created.



R. Schoenberg
1999-03-29