I'm afraid that that documentation is still lacking. You can achieve what you
want, but it is somewhat convoluted:
1. call DoForecasting
2. extract m_mDynForc
Some more information is below,
Regards, Jurgen
The forecast dialog of PcGive time-series modelling calls:
DoForecasting(
iPlot, // -1: no plotting, >= 0 first plot area
const cH, // 0: dynamic forecasts, > 0: h-step forecasts
iSEtype, // SE type, 0=Do not compute, 1=Error variance,
// 2=With parameter uncertainty
const iBarType, // bar type in plots
const dCrit, // critical value for error bars
const cTpre, // no of pre-forecast obs in plot
const viSel); // index of dependent variables to plot
// use <0> for univariate
The forecasts are stored in the following member variables
m_mDynForc: (F x n) matrix with forecasts, where n is the number of
dependent variables plus derived functions
m_sDynForc: text label
m_cDynForc: cH
There is no export function for m_mDynForc, so you need to use a derived
class along the following lines:
class PcGive : PcGiveCore
{
PcGive();
GetForecasts();
};
PcGive::GetForecasts()
{
return m_mDynForc;
}
oxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxox
oxoxoxox Oxford Summer School 2012, 7-14 July
oxoxoxox 12th OxMetrics user conference 2012
oxoxoxox Cass Business School, London, 3-4 September
oxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxox
Dr Jurgen A Doornik
James Martin Fellow, Institute for New Economic Thinking
at the Oxford Martin School, University of Oxford
tel. UK: +44-1865-278610 at Nuffield College
http://www.doornik.com
http://www.oxmetrics.net
oxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxoxox
On 2012-07-26 11:24, Taylor, George wrote:
> When using the batch facility in OxMetrics it is possible to produce forecasts
> by entering the command “forecast(5,0,1);” into the batch window below the
> instructions for model estimation produced by the OxMetrics. I’d like to be able
> to achieve the same result with an Ox program using the PCGive class catching
> the results (including the standard errors)in an array / matrix rather than
> printing them.
> I’ve been reading through the pcgivecore.h file but nothing obvious has jumped
> out at me, is there any documentation regarding what the various methods of the
> pcgive classes do and what the parameters passed into these methods refer to?
> Many Thanks
> George Taylor
> Senior Forecasting Analyst
> Demand Forecasting
> Eon Energy Solutions
>
> ___________________________ Disclaimer Notice ______________________
> This message and any attachments are confidential and should only be read by
> those to whom they are addressed. If you are not the intended recipient, please
> contact us, delete the message from your computer and destroy any copies. Any
> distribution or copying without our prior permission is prohibited.
>
> Internet communications are not always secure and therefore E.ON
> does not accept legal responsibility for this message. The recipient is
> responsible for verifying its authenticity before acting on the contents. Any
> views or opinions presented are solely those of the author and do not
> necessarily represent those of E.ON.
>
> Registered addresses:
>
> E.ON UK Plc, Westwood Way, Westwood Business Park, Coventry, CV4 8LG.
> Registered in England and Wales No. 2366970
>
> E.ON Energy Solutions Limited, Westwood Way, Westwood Business Park, Coventry,
> CV4 8LG.
> Registered in England and Wales No. 3407430
>
>
> Telephone +44 (0) 2476 192000
> Fax +44 (0) 2476 42 5432
>
|