I am fairly new to SPSS and completely new to writing my own Syntax, but I am very excited about learning to use what I think will be a very useful and powerful tool. We are working on a project where we have survey data from approximately 350 respondents and each respondent was able to choose a product to rate. I created a custom table (without writing my own syntax) to get the Mean and Standard Deviation for each survey rating question with Product as a layer. I then created a bar chart of that data. The way I found to do this was by opening up the table from the output window and going to Edit>Create Graph>bar. I need to include the custom table and bar chart for each product in a report. I was able to create a template for how I want my bar charts to look, but I can not find a way to paste the syntax from the bar chart. I have searched online for information but am not finding anything on custom table car charts. I would like to find a way to write the syntax so it loops through each product and creates a custom table and bar chart for each one in my output file. Does anyone have any ideas on how this can be done or where a good place to look for information on this would be?
===================== 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 |
Creating a chart directly from a table is done without syntax - it is meant for interactive exploration. To create charts from syntax, start with Graphs > Chart Builder. It offers you a canvas for constructing your chart in a way that is similar to the Custom Tables canvas. Depending on how you want the output ordered, there may be other things to consider, but start by getting the right chart setup. On Tue, Apr 26, 2016 at 7:25 AM, LaTosha Renfro <[hidden email]> wrote: I am fairly new to SPSS and completely new to writing my own Syntax, but I am very excited about learning to use what I think will be a very useful and powerful tool. We are working on a project where we have survey data from approximately 350 respondents and each respondent was able to choose a product to rate. I created a custom table (without writing my own syntax) to get the Mean and Standard Deviation for each survey rating question with Product as a layer. I then created a bar chart of that data. The way I found to do this was by opening up the table from the output window and going to Edit>Create Graph>bar. I need to include the custom table and bar chart for each product in a report. I was able to create a template for how I want my bar charts to look, but I can not find a way to paste the syntax from the bar chart. I have searched online for information but am not finding anything on custom table car charts. I would like to find a way to write the syntax so it loops through each product and creates a custom table and bar chart for each one in my output file. Does anyone have any ideas on how this can be done or where a good place to look for information on this would be? |
Jon, Thank you for your help with this problem. After reading your response I switched gears and started trying to create the charts using Chart Builder but I am
not coming up with the results I need. Let’s say I have 30 different products. I then want 30 different charts where each product generates its own chart with that product’s mean for each of the 20 rating questions. I am not seeing a way to add product
as a layer to generate individual reports. Ultimately, I would like to be able to create this where my output file has a table (showing the question name, mean, and standard deviation for each question) for product 1 followed by the chart for product 1 and
then the table for product 2, chart for product 2, etc. Does that make it clearer what I am needing, and do you have any ideas on how to do it? I would appreciate any thoughts you have on how to approach finding a solution to this problem.
-LaTosha From: Jon Peck [mailto:[hidden email]]
The e-mail below is from an external source. Please do not open attachments or click links from an unknown or suspicious origin. Creating a chart directly from a table is done without syntax - it is meant for interactive exploration. To create charts from syntax, start with Graphs > Chart Builder. It offers you a canvas for constructing
your chart in a way that is similar to the Custom Tables canvas. Depending on how you want the output ordered, there may be other things to consider, but start by getting the right chart setup. On Tue, Apr 26, 2016 at 7:25 AM, LaTosha Renfro <[hidden email]> wrote:
-- Jon K Peck NOTICE: This electronic mail message and any files transmitted with it are intended |
Can you get the chart you need for just one instance? Then we could automate iterating over these. If the ratings are all separate questions, this gets a bit trickier. If you can send me a sample of the data, I can look into this. On Wed, Apr 27, 2016 at 11:37 AM, LaTosha Renfro <[hidden email]> wrote:
|
Jon, As luck would have it we have the trickier variety; the ratings are all for separate questions. I have not found a way to create the graph for a single product,
yet. When I try it in Chart Builder the best I can come up with is a single chart that has a grouping for each product. The only way I was able to create a chart for a single product was when I created a custom table first. I had product as a layer there,
so I was able to pick a product to create the chart for, but I was not able to get the syntax for that to loop through and create a chart for each product. I have not found a way to add a layer in Chart Builder. Here is a sample of the data if there is a
different format you would rather have this in please let me know.
Thank you for looking into this! From: Jon Peck [mailto:[hidden email]]
The e-mail below is from an external source. Please do not open attachments or click links from an unknown or suspicious origin. Can you get the chart you need for just one instance? Then we could automate iterating over these. If the ratings are all separate questions, this gets a bit trickier. If you can send me a sample of the
data, I can look into this. On Wed, Apr 27, 2016 at 11:37 AM, LaTosha Renfro <[hidden email]> wrote:
-- Jon K Peck NOTICE: This electronic mail message and any files transmitted with it are intended |
Free forum by Nabble | Edit this page |