Print several values of statistical MODA

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

Print several values of statistical MODA

Javier Figueroa

SPSS Hello experts, I hope that all its activities are being met successfully.

I am generating a report check prices of lubricants and need to print the modal value cadaq price for its channel (Total, wholesalers, oil and spare parts) in SPSS me print only one modal value but I've noticed viewing data that several modal values, I would print all your% modal values, then selecting the most significant, I could help with this, your help would be very grateful.

Below I detail what I need, marked with yellow printing modal values SPSS and sky that I want I also would print.

  Marcas
Total
Punto de venta
Total Aceitera Venta de repuestos Mayorista
P4. TAMAÑO /PRESENTACIÓN Galón (3.785Lts) 16.00 %V 1%   -   - 13%
19.75 %V 1%   - 1%   -
19.86 %V 1%   -   - 13%
20.00 %V 5% 4% 7%   -
20.15 %V 1% 2%   -   -
21.95 %V 1%   - 1%   -
21.99 %V 1%   -   - 13%
22.00 %V 9% 4% 13%   -
22.10 %V 1%   - 1%   -
24.75 %V 1%   - 1%   -
24.95 %V 1% 2%   -   -
25.00 %V 9% 7% 10%   -
25.30 %V 1% 2%   -   -
25.50 %V 1%   - 2%   -
26.00 %V 8% 9% 7% 13%
26.40 %V 1% 2%   -   -
26.60 %V 1%   - 1% 13%
26.70 %V 1%   - 1%   -
26.90 %V 1% 2%   -   -
27.00 %V 4% 6% 3%   -
27.50 %V 1%   - 1%   -
27.60 %V 1% 4%   -   -
28.00 %V 6% 9% 5%   -
28.40 %V 1%   - 1%   -
28.50 %V 1%   - 1%   -
Total %V 100% 100% 100% 100%
Media 24.44 25.74 23.94 21.21
Moda 22.00 26.00 22.00 16.00
Moda 2 25.00      
Moda 3 26.00      
Moda 4 28.00      
Moda 5 20.00      
Mediana 24.85 26.00 24.00 20.81
Desviación típica 3.83 3.96 3.49 3.69
Mínimo 16.00 18.00 17.00 16.00
Máximo 37.01 35.00 37.01 26.60
N válido 150 54 88 8
Sincerely,
--
Javier Figueroa
Procesamiento y Análisis de bases de datos
Cel: 5927-4748 / 4970-1940
Casa: 2289-0184

===================== 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: Print several values of statistical MODA

David Marso
Administrator
<templated to fill in>

AGGREGATE OUTFILE * / BREAK <varname> / Count=N .
SORT CASES BY Count(D).
IF $CASENUM=1 Modal=1.
IF $CASENUM GT 1 AND Count=LAG(Count) Modal=1.
DO IF Modal.
PRINT <varname>.
END IF.

If you have subcategories then this can easily be generalized with added breaks and conditions on the lagged variables.

If you want this for multiple variables see VARSTOCASES to do prior to AGGREGATE.
BTW, YELLOW does NOT SHOW UP ON WHITE!  PICK A DIFFERENT COLOR NEXT TIME.
Light Blue isn't so hot either.
Maybe try BOLD!

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: Print several values of statistical MODA

Javier Figueroa
Thank you very much David

But I think I did not explain well what I need, and that is that I have a database with variables,

ID_Nuncue = Id Questionnaire
Marcas = Brand
P4 = Presentation
P5 = Price

To generate my table, with custom tables and specify the statistical I need, which will appear to me as an example several values ​​of Fashion and SPSS prints only the smallest of all values ​​of Fashion and I need you to print the most representative, in the example the mark with yellow print and SPSS a blue that I want I also printed in the output file.

Eg. In the database

ID_Nuncue    Brands                                                                                     P4                                      P5
1                   Castrol - GTX 10W30                                                               Gallon (3.785Lts)                  27.00
1                   Gallon 10W30 MINERAL                                                            (3.785Lts)                          22.75
2                   VALVOLINE - Gallon 10W30 MINERAL (3.785Lts)                                                                20.00
2                   Mobile - Gallon 10W30 MINERAL (3.785Lts)                                                                         23.00
3                   Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                27.00
3                   VALVOLINE - Gallon 20W50 MINERAL (3.785Lts)                                                                20.00
13                 MOBIL - Gallon 20W50 MINERAL (3.785Lts)                                                                        20.00
17                 Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                27.00
33                 Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                23.00

In this example SPSS imprimiería the lowest (20.00) and I need you in the output file print me 20.00, 27.00 and 23.00 as in the previous example.

I put colors to mark only, not anything relevant, but what if I need is the statistical appear as in the example.

I've been doing manually

in advance thank you for your help,

Sincerely,


2015-11-24 18:08 GMT-06:00 David Marso <[hidden email]>:
<templated to fill in>

AGGREGATE OUTFILE * / BREAK <varname> / Count=N .
SORT CASES BY Count(D).
IF $CASENUM=1 Modal=1.
IF $CASENUM GT 1 AND Count=LAG(Count) Modal=1.
DO IF Modal.
PRINT <varname>.
END IF.

If you have subcategories then this can easily be generalized with added
breaks and conditions on the lagged variables.

If you want this for multiple variables see VARSTOCASES to do prior to
AGGREGATE.
BTW, YELLOW does NOT SHOW UP ON WHITE!  PICK A DIFFERENT COLOR NEXT TIME.
Light Blue isn't so hot either.
*Maybe try BOLD!*





-----
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?"
--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Print-several-values-of-statistical-MODA-tp5731035p5731044.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



--
Javier Figueroa
Procesamiento y Análisis de bases de datos
Cel: 5927-4748 / 4970-1940
Casa: 2289-0184

===================== 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
|

Fwd: Print several values of statistical MODA

Javier Figueroa
Hello again SPSS experts, I hope you can help me with some suggestions of how to work this case.

I explain:

If two or more scores with the same frequency in a group and that frequency is high, the distribution is bimodal or multimodal, ie has several fashions.

1, 1, 1, 4, 4, 5, 5, 5, 7, 8, 9, 9, 9Mo = 1, 5, 9

In SPSS we generate custom tables when only shows a modal value and in this particular case I need to show all modal values that appear in the file salilda generated by the Custom Tables dialog box.

if they could help me or give me an example of how to do this process, I will be very grateful.

Beforehand thank you very much

Sincerely,

---------- Forwarded message ----------
From: Javier Figueroa <[hidden email]>
Date: 2015-11-25 10:01 GMT-06:00
Subject: Re: Print several values of statistical MODA
To: David Marso <[hidden email]>
Cc: [hidden email]


Thank you very much David

But I think I did not explain well what I need, and that is that I have a database with variables,

ID_Nuncue = Id Questionnaire
Marcas = Brand
P4 = Presentation
P5 = Price

To generate my table, with custom tables and specify the statistical I need, which will appear to me as an example several values ​​of Fashion and SPSS prints only the smallest of all values ​​of Fashion and I need you to print the most representative, in the example the mark with yellow print and SPSS a blue that I want I also printed in the output file.

Eg. In the database

ID_Nuncue    Brands                                                                                     P4                                      P5
1                   Castrol - GTX 10W30                                                               Gallon (3.785Lts)                  27.00
1                   Gallon 10W30 MINERAL                                                            (3.785Lts)                          22.75
2                   VALVOLINE - Gallon 10W30 MINERAL (3.785Lts)                                                                20.00
2                   Mobile - Gallon 10W30 MINERAL (3.785Lts)                                                                         23.00
3                   Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                27.00
3                   VALVOLINE - Gallon 20W50 MINERAL (3.785Lts)                                                                20.00
13                 MOBIL - Gallon 20W50 MINERAL (3.785Lts)                                                                        20.00
17                 Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                27.00
33                 Castrol - GTX 20W50 Gallon (3.785Lts)                                                                                23.00

In this example SPSS imprimiería the lowest (20.00) and I need you in the output file print me 20.00, 27.00 and 23.00 as in the previous example.

I put colors to mark only, not anything relevant, but what if I need is the statistical appear as in the example.

I've been doing manually

in advance thank you for your help,

Sincerely,


2015-11-24 18:08 GMT-06:00 David Marso <[hidden email]>:
<templated to fill in>

AGGREGATE OUTFILE * / BREAK <varname> / Count=N .
SORT CASES BY Count(D).
IF $CASENUM=1 Modal=1.
IF $CASENUM GT 1 AND Count=LAG(Count) Modal=1.
DO IF Modal.
PRINT <varname>.
END IF.

If you have subcategories then this can easily be generalized with added
breaks and conditions on the lagged variables.

If you want this for multiple variables see VARSTOCASES to do prior to
AGGREGATE.
BTW, YELLOW does NOT SHOW UP ON WHITE!  PICK A DIFFERENT COLOR NEXT TIME.
Light Blue isn't so hot either.
*Maybe try BOLD!*





-----
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?"
--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Print-several-values-of-statistical-MODA-tp5731035p5731044.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



--
Javier Figueroa
Procesamiento y Análisis de bases de datos
Cel: 5927-4748 / 4970-1940
Casa: 2289-0184




--
Javier Figueroa
Procesamiento y Análisis de bases de datos
Cel: 5927-4748 / 4970-1940
Casa: 2289-0184

===================== 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: Fwd: Print several values of statistical MODA

David Marso
Administrator
I showed you how to calculate/flag the multiple modes.  How you decide to display them is another matter.
I don't have CTABLES installed and most people here don't write custom TABLES code so best of luck.
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: Fwd: Print several values of statistical MODA

Mario Giesel
Javier,

  it is correct: Summary function MODE shows the most frequent value but if there is a tie, the
smallest value is shown. There is imho no specification that allows to mention several modes comma separated or something within CTABLES functionality.

As it would take time to write a remedy via syntax I would rather think about investigating modality in a separate table which should suffice in most practical cases.

GL,
  Mario





David Marso <[hidden email]> schrieb am 0:58 Freitag, 4.Dezember 2015:




I showed you how to calculate/flag the multiple modes.  How you decide to
display them is another matter.
I don't have CTABLES installed and most people here don't write custom
TABLES code so best of luck.



-----
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?"
--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Print-several-values-of-statistical-MODA-tp5731035p5731089.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
Mario Giesel
Munich, Germany
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Print several values of statistical MODA

Javier Figueroa
David, thank you very much, I worked perfectly explained to me the procedure to calculate various fashions.
Mario thanks for answering my request.
The fact is that particularly for this project I seek to do this, show all significant modal values, this work is done repeatedly in several paices and touched me do this several times I have been doing in excel and wanted to simplify the process. I understand all the inconveniences that this may cause but lose nothing by asking and so know if my request esra possible to do so and make my life a little easier. Hahaha,
thank you again, are an excellent team and they do a very good work which is helping others.

Sincerely,

2015-12-04 6:36 GMT-06:00 Mario Giesel <[hidden email]>:
Javier,

  it is correct: Summary function MODE shows the most frequent value but if there is a tie, the
smallest value is shown. There is imho no specification that allows to mention several modes comma separated or something within CTABLES functionality.

As it would take time to write a remedy via syntax I would rather think about investigating modality in a separate table which should suffice in most practical cases.

GL,
  Mario





David Marso <[hidden email]> schrieb am 0:58 Freitag, 4.Dezember 2015:




I showed you how to calculate/flag the multiple modes.  How you decide to
display them is another matter.
I don't have CTABLES installed and most people here don't write custom
TABLES code so best of luck.



-----
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?"
--
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Print-several-values-of-statistical-MODA-tp5731035p5731089.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



--
Javier Figueroa
Procesamiento y Análisis de bases de datos
Cel: 5927-4748 / 4970-1940
Casa: 2289-0184

===================== 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