Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Count answers filtered by response

  • hribeiro
  • hribeiro's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago - 2 years 6 months ago #220555 by hribeiro
Count answers filtered by response was created by hribeiro
Hi All
First of all thank you for this wonderful community supporting a great tool.

What I'm trying to do is to have some kind of stats - ideally a simple page - where I can show some counts about the answers filtered by other answers.
For example, if I have Q1 asking Gender, and then Q2 asking for favourite fruit, I would like to have a simple page/stats saying Males preferring Banana = X; Females preferring Apples = Y.

How Is this possible? Is there any core setting, plugin or would I need to use the API?

Thanks in advance
Last edit: 2 years 6 months ago by hribeiro.
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago - 2 years 6 months ago #220557 by Joffm
Replied by Joffm on topic Count answers filtered by response
Hi,
please always mention which version of LimeSurvey you are using.
In this case this is very important.
Since Version 5.x. there is a built in plugin "statFunctions", in versions before you may use the plugin "getStatInSurvey"
[url] gitlab.com/SondagesPro/ExportAndStats/getStatInSurvey [/url]

Both functions do not count combinations in the dataset.
So you have to create a question (hidden), where you set the combinations,
like list(radio)
1: male - bananas
2: male - apples
3: female - bananas
4: female - apples
...
 and you set the question by an equation like
{if(QGender==codeOfMale,if(QFruit==codeOfBanana,1,2),if(QFruit==codeOfBanana,3,4))}
or in a longer version 
{if(QGender==codeOfMale and QFruit==codeOfBanana,1,if(QGender==codeOfMale and QFruit==codeOfApple,2,if(QGender==codeOfFemale and QFruit==codeOfBanana,3,4)))}
Then you can count by the plugin, how many times code 1 was selected, code 2 was selected, ...

Joffm
 

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 2 years 6 months ago by Joffm.
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220568 by DenisChenu
Replied by DenisChenu on topic Count answers filtered by response
1st question : LimeSurvey version number ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
  • hribeiro
  • hribeiro's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago - 2 years 6 months ago #220570 by hribeiro
Replied by hribeiro on topic Count answers filtered by response
Thank you.
I'm exploring my options because I'm at an dev environment. At this stage I' m using 3.27.19 but if needed I could install a different version
Last edit: 2 years 6 months ago by hribeiro.
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220572 by DenisChenu
Replied by DenisChenu on topic Count answers filtered by response

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
  • hribeiro
  • hribeiro's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago #220575 by hribeiro
Replied by hribeiro on topic Count answers filtered by response
Thank you Denis. Yesterday I was exploring your plugins but I need to go deeper.
Would I be able to publish those stats only for an admin, for example before starting a new set of responses?
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220582 by Joffm
Replied by Joffm on topic Count answers filtered by response

I would like to have a simple page/stats saying Males preferring Banana = X; Females preferring Apples = Y.

So you would like to have it for your analysis?
LimeSurvey is not an analysing tool, these things you do in the special tool like SPSS, SAS, PSPP, R, EXCEL, whatever.
It's a simple thing of cross tabulation (Pivot table in EXCEL.)

for example before starting a new set of responses?

In the LimeSurvey "statistics" you have to filter for one attribute (like "gender ->male") to get the results for this subsample.
Then you filter the other "gender->female".

Joffm

 

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #220583 by DenisChenu
Replied by DenisChenu on topic Count answers filtered by response

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose