Overlay Descriptives to SPSS Graph

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

Overlay Descriptives to SPSS Graph

GeorgeH
I am producing a large number of charts. I want to be able to add syntax to
my standard gplot syntax for all the charts that adds the sample size and
the number of missing to the body of the plot. Is this possible to do? And
if so, how.

Thanks

George

--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Overlay-Descriptives-to-SPSS-Graph-tp5710297.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
Reply | Threaded
Open this post in threaded view
|

Re: Overlay Descriptives to SPSS Graph

David Marso
Administrator
Something like that could *probably* be done using Python or Basic Scripting but I'm not going to write it for you.
Start with trying to add a dummy N and Missing to the body and then go from there.
If that can be done then use scripting to
1. generate a table/data set of N and Missing for each chart.
2. parse the table and generate the appropriate chart syntax using the values from the table.
Might be a huge PIA.  If you figure it out please repost the solution for the benefit of the list.
Best of luck.
---
GeorgeH wrote
I am producing a large number of charts. I want to be able to add syntax to
my standard gplot syntax for all the charts that adds the sample size and
the number of missing to the body of the plot. Is this possible to do? And
if so, how.

Thanks

George

--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Overlay-Descriptives-to-SPSS-Graph-tp5710297.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
Please reply to the list and not to my personal email.
Those desiring my consulting or training services please feel free to email me.
---
"Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis."
Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?"
Reply | Threaded
Open this post in threaded view
|

Re: Overlay Descriptives to SPSS Graph

Jon K Peck
In reply to this post by GeorgeH
There is no gplot command in Statistics, but if you are using GGRAPH, you could do this through GPL as a subtitle or footnote, among other possibilities.  But you need to know the N and missing count to insert them.  Generating the requisite GPL would be best done through programmability.  I can elaborate if you want to go this route.

Jon Peck (no "h") aka Kim
Senior Software Engineer, IBM
[hidden email]
new phone: 720-342-5621




From:        GeorgeH <[hidden email]>
To:        [hidden email]
Date:        05/15/2012 01:21 PM
Subject:        [SPSSX-L] Overlay Descriptives to SPSS Graph
Sent by:        "SPSSX(r) Discussion" <[hidden email]>




I am producing a large number of charts. I want to be able to add syntax to
my standard gplot syntax for all the charts that adds the sample size and
the number of missing to the body of the plot. Is this possible to do? And
if so, how.

Thanks

George

--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Overlay-Descriptives-to-SPSS-Graph-tp5710297.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


Reply | Threaded
Open this post in threaded view
|

Re: Overlay Descriptives to SPSS Graph

GeorgeH
You're right, it is GGRAPH. My problem is I know a little about a lot of different applications and sometimes I don't transition well. gplot was a poorly constructed aggregation of R and SPSS (ggplot + ggraph) and it's still wrong anyway. The only thing I got correct was the "g". Sorry about that.
 
I would like to go this route. Here is how I have been trying to break down the process.  I have a lot of variables that need individual charts. They have varying "n's" based on number that said yes. For example var1 = 5467 yes's and var2=2301 yes's. Yes = 1; No = 0 I thought I could just reference the "n" = yes or 1 for each var in some code that then attaches that "n" to a graph, I wanted to do the same for the missing "n". But i am realizing that probably can't happen.
 
I thought I could create new vars that just count or sum the number of yes's or 1's so each case would have the same N per variable. So for var1 = 5467 I would have var1_n=5467 for each case. I thought this would at least be easy. I can't even get that to work. I can do it indivudally, such as "compute var1_n=5467". Which I can do, that's just tedious, not hard.  For 376 variables I can just copy, paste and edit.
 
So the real problem is how do I, through a more automated way using syntax, attach that indivdual N to each individual graph using chart builder? Is there a way to reference that new N variable in a footnote using syntax? Or is there a better way to do any of this.
 
Further limitations: I have never used python.
 
G (for George not ggplot or ggraph).

 
On Wed, May 16, 2012 at 8:59 AM, Jon K Peck <[hidden email]> wrote:
There is no gplot command in Statistics, but if you are using GGRAPH, you could do this through GPL as a subtitle or footnote, among other possibilities.  But you need to know the N and missing count to insert them.  Generating the requisite GPL would be best done through programmability.  I can elaborate if you want to go this route.

Jon Peck (no "h") aka Kim
Senior Software Engineer, IBM
[hidden email]
new phone: <a href="tel:720-342-5621" target="_blank" value="+17203425621">720-342-5621




From:        GeorgeH <[hidden email]>
To:        [hidden email]
Date:        05/15/2012 01:21 PM
Subject:        [SPSSX-L] Overlay Descriptives to SPSS Graph
Sent by:        "SPSSX(r) Discussion" <[hidden email]>




I am producing a large number of charts. I want to be able to add syntax to
my standard gplot syntax for all the charts that adds the sample size and
the number of missing to the body of the plot. Is this possible to do? And
if so, how.

Thanks

George

--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Overlay-Descriptives-to-SPSS-Graph-tp5710297.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



Reply | Threaded
Open this post in threaded view
|

Re: Overlay Descriptives to SPSS Graph

GeorgeH
Now, I did this and could get the N of the yes's "as long as I change my 0's to missing) using this code (and so simple):
 
agg  /q0001_N = nu(q0001).
 
So that part is solved. Now how to attach to the graph. I'll let you know if I figure that out.
 
G.

On Wed, May 16, 2012 at 9:49 AM, George Hamlin <[hidden email]> wrote:
You're right, it is GGRAPH. My problem is I know a little about a lot of different applications and sometimes I don't transition well. gplot was a poorly constructed aggregation of R and SPSS (ggplot + ggraph) and it's still wrong anyway. The only thing I got correct was the "g". Sorry about that.
 
I would like to go this route. Here is how I have been trying to break down the process.  I have a lot of variables that need individual charts. They have varying "n's" based on number that said yes. For example var1 = 5467 yes's and var2=2301 yes's. Yes = 1; No = 0 I thought I could just reference the "n" = yes or 1 for each var in some code that then attaches that "n" to a graph, I wanted to do the same for the missing "n". But i am realizing that probably can't happen.
 
I thought I could create new vars that just count or sum the number of yes's or 1's so each case would have the same N per variable. So for var1 = 5467 I would have var1_n=5467 for each case. I thought this would at least be easy. I can't even get that to work. I can do it indivudally, such as "compute var1_n=5467". Which I can do, that's just tedious, not hard.  For 376 variables I can just copy, paste and edit.
 
So the real problem is how do I, through a more automated way using syntax, attach that indivdual N to each individual graph using chart builder? Is there a way to reference that new N variable in a footnote using syntax? Or is there a better way to do any of this.
 
Further limitations: I have never used python.
 
G (for George not ggplot or ggraph).

 
On Wed, May 16, 2012 at 8:59 AM, Jon K Peck <[hidden email]> wrote:
There is no gplot command in Statistics, but if you are using GGRAPH, you could do this through GPL as a subtitle or footnote, among other possibilities.  But you need to know the N and missing count to insert them.  Generating the requisite GPL would be best done through programmability.  I can elaborate if you want to go this route.

Jon Peck (no "h") aka Kim
Senior Software Engineer, IBM
[hidden email]
new phone: <a href="tel:720-342-5621" target="_blank" value="+17203425621">720-342-5621




From:        GeorgeH <[hidden email]>
To:        [hidden email]
Date:        05/15/2012 01:21 PM
Subject:        [SPSSX-L] Overlay Descriptives to SPSS Graph
Sent by:        "SPSSX(r) Discussion" <[hidden email]>




I am producing a large number of charts. I want to be able to add syntax to
my standard gplot syntax for all the charts that adds the sample size and
the number of missing to the body of the plot. Is this possible to do? And
if so, how.

Thanks

George

--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/Overlay-Descriptives-to-SPSS-Graph-tp5710297.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