decomposing into positive and negative series

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator

roger02
Posts: 14
Joined: Wed Dec 10, 2008 12:06 pm

decomposing into positive and negative series

Postby roger02 » Mon Jul 20, 2009 10:41 pm

dear moderator,
i need to seperate the positive values of one series from the negative values( with their corresponding dates) , i think i tried my best but couldnt do it.
please some advice here.
regards

startz
Non-normality and collinearity are NOT problems!
Posts: 3775
Joined: Wed Sep 17, 2008 2:25 pm

Re: decomposing into positive and negative series

Postby startz » Tue Jul 21, 2009 6:53 am

roger02 wrote:dear moderator,
i need to seperate the positive values of one series from the negative values( with their corresponding dates) , i think i tried my best but couldnt do it.
please some advice here.
regards

Code: Select all

series pos
series neg
smpl if x>0
pos=x
smpl if x<0
neg=x
smpl @all

roger02
Posts: 14
Joined: Wed Dec 10, 2008 12:06 pm

Re: decomposing into positive and negative series

Postby roger02 » Tue Jul 21, 2009 7:28 am

how amazing!!
just quite happy to see how its easy in eviews, however, the NA is still in each new series
and i would love to get red of them, please help in here
thanx

startz
Non-normality and collinearity are NOT problems!
Posts: 3775
Joined: Wed Sep 17, 2008 2:25 pm

Re: decomposing into positive and negative series

Postby startz » Tue Jul 21, 2009 7:34 am

Just set the series to whatever initial value you prefer to NA.

roger02
Posts: 14
Joined: Wed Dec 10, 2008 12:06 pm

Re: decomposing into positive and negative series

Postby roger02 » Tue Jul 21, 2009 8:50 am

thank you for your quick reply


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 25 guests