This is great Reccardo!

Thank you so much. I have to invest in learning to code in Gretl a bit.

On Thu, Jan 31, 2019 at 8:49 AM Riccardo (Jack) Lucchetti <> wrote:
On Thu, 31 Jan 2019, Periklis Gogas wrote:

> I am working on oil prices "WTI"
> Is it possible to create within Gretl a dummy that takes the value 1 when
> WTI goes up and 0 when WTI goes down?
> For example within Excel for a column A that contains WTI it is something
> like IF(A2>A1,1,0).

Something like

series WTIdum = diff(WTI) > 0

should do.

   Riccardo (Jack) Lucchetti
   Dipartimento di Scienze Economiche e Sociali (DiSES)

   Università Politecnica delle Marche
   (formerly known as Università di Ancona)
Gretl-users mailing list