Combine bar line chart in one?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Combine bar line chart in one?

maarcc2005
Hi.

I'm new to SPSS.

I would like to draw a chart that shows a cluster bar chart combined with the line trend in the same diagram. Is this possible? How do I do it?

The bar and the line charts are essentially the same charts as they come from the same data with all things remain the same. Just the display is differnet. One is cluster bar, one is line. I just need to present both in one chart. I have been checking and reading but saw nothing.

Please advise.

Thank you.
Marc
Reply | Threaded
Open this post in threaded view
|

Re: Combine bar line chart in one?

ViAnn Beadle
You should be able to do it with the GGRAPH command and GPL although the
clustering might be a bit problematical. There is an example of a dual axis
graph in the GPL section of Help. We need much more info to steer you in the
right direction.

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of
maarcc2005
Sent: Thursday, April 07, 2011 7:34 AM
To: [hidden email]
Subject: Combine bar line chart in one?

Hi.

I'm new to SPSS.

I would like to draw a chart that shows a cluster bar chart combined with
the line trend in the same diagram. Is this possible? How do I do it?

The bar and the line charts are essentially the same charts as they come
from the same data with all things remain the same. Just the display is
differnet. One is cluster bar, one is line. I just need to present both in
one chart. I have been checking and reading but saw nothing.

Please advise.

Thank you.
Marc

--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Combine-bar-line-chart-in-one-
tp4288553p4288553.html
Sent from the SPSSX Discussion mailing list archive at Nabble.com.

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command SIGNOFF SPSSX-L For a list of
commands to manage subscriptions, send the command INFO REFCARD

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD
Reply | Threaded
Open this post in threaded view
|

Recoding string to numeric variable

Khaing Soe-2
Dear All,
 
I would like to seed advice on recoding numeric variable to string variable
I changed numeric to string in variable view and following command was given; but didnt work.
 
STRING township (A10).
RECODE hh1 ('101', '102', '103' ='shwebo')  (ELSE= COPY) INTO township.
 
The error message is as follows;

The RECODE command specifies a value to be assigned that is longer than some

variable(s) in the recode. The values will be truncated to the variable's

length.

 
I dont know what's wrong with it and pease advise.
Regards,
Khaing Soe

 

Reply | Threaded
Open this post in threaded view
|

Re: Recoding string to numeric variable

Maguin, Eugene
Khaing Soe,
 
The error message really is informative. It says that a value to be assigned (that would be a value in hh1) is longer than some variable in the recode (that would be township). You've defined township as being 10 characters long. I'll be hh1 has a value that is longer than 10 characters. If you do a frequencies on hh1, how long is the longest value?
 
Gene Maguin


From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Khaing Soe
Sent: Friday, April 08, 2011 2:26 AM
To: [hidden email]
Subject: Recoding string to numeric variable

Dear All,
 
I would like to seed advice on recoding numeric variable to string variable
I changed numeric to string in variable view and following command was given; but didnt work.
 
STRING township (A10).
RECODE hh1 ('101', '102', '103' ='shwebo')  (ELSE= COPY) INTO township.
 
The error message is as follows;

The RECODE command specifies a value to be assigned that is longer than some

variable(s) in the recode. The values will be truncated to the variable's

length.

 
I dont know what's wrong with it and pease advise.
Regards,
Khaing Soe

 

Reply | Threaded
Open this post in threaded view
|

Re: Recoding string to numeric variable

Bruce Weaver
Administrator
In reply to this post by Khaing Soe-2
Here's a guess at what you are trying to do.  It assumes that HH1 is a numeric variable originally.  If this is not what you want to do, please clarify.


* Sample data with HH1 as a NUMERIC variable.
data list free / hh1 (f5.0).
begin data
101 102 103 104 105 106
end data.

string township (a10).
do if any(hh1,101,102,103).
- compute township = 'shwebo'.
else.
- compute township = LTRIM(string(hh1,f5)).
end if.
list.


Khaing Soe-2 wrote
Dear All,

I would like to seed advice on recoding numeric variable to string variable
I changed numeric to string in variable view and following command was given;
but didnt work.


STRING township (A10).
RECODE hh1 ('101', '102', '103' ='shwebo')  (ELSE= COPY) INTO township.

The error message is as follows;
The RECODE command specifies a value to be assigned that is longer than some
variable(s) in the recode. The values will be truncated to the variable's
length.

I dont know what's wrong with it and pease advise.
Regards,
Khaing Soe


________________________________
--
Bruce Weaver
bweaver@lakeheadu.ca
http://sites.google.com/a/lakeheadu.ca/bweaver/

"When all else fails, RTFM."

PLEASE NOTE THE FOLLOWING: 
1. My Hotmail account is not monitored regularly. To send me an e-mail, please use the address shown above.
2. The SPSSX Discussion forum on Nabble is no longer linked to the SPSSX-L listserv administered by UGA (https://listserv.uga.edu/).