The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Can Origin do this?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

mwarner

USA
30 Posts

Posted - 06/03/2008 :  5:59:43 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin): 8.0
Operating System:Win 2000

I have a data set broken up by year, from 1901 to 2008 down one X column and then monthly data for each year as each column next to that. I want to plot one contiguous line of all the data across time, but as set up, Origin wants to plot 12 individual lines across time so there is no way to have one single line and then do other things like rolling averages. Does anyone know of a way to convert data sets like this in Origin to one single data stream?

greg

USA
1380 Posts

Posted - 06/10/2008 :  3:21:11 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Assuming your years are in column 1 and your months are numbers in column 2, and we arbitrarily decide on the first of the month, then a script like this will work:

wks.col=3;
wks.insert(Date);
wks.col3.format=4;
get col(1) -e end;
loop(ii,1,end) {
%L = wcol(1)[ii]$;
%M = wcol(2)[ii]$;
val = date(%M/01/%L);
col(Date)[ii]=val;
}

If your month column has text like 'Jan' or 'January', make sure your column format is set to Month and Display type matches.

Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000