python - Analysis method for categorical survey -


i have survey response following:

q1              q2                              q3  satisfied  shorter expected    10 satisfied  expected           10 satisfied  expected           8 satisfied  shorter expected    10 satisfied       expected           4 satisfied  shorter expected    10 satisfied       expected           8 satisfied       shorter expected    10 satisfied  shorter expected         9 satisfied  shorter expected    10 satisfied       shorter expected         8 satisfied       expected           8 satisfied       shorter expected         5 satisfied  shorter expected         10 satisfied  shorter expected    9 satisfied  shorter expected    10 satisfied       shorter expected    9 satisfied  expected           9 satisfied  expected           10 satisfied  shorter expected         10 satisfied  shorter expected    10 satisfied  expected           10 neutral         shorter expected         8 satisfied  shorter expected         6 satisfied       expected           8 satisfied  shorter expected    10 satisfied  shorter expected         9 unsatisfied     expected           3 satisfied  shorter expected    10 satisfied       shorter expected         9 neutral         shorter expected         6 unsatisfied     did not receive response      1 satisfied  shorter expected    10 unsatisfied    expected       1 satisfied  shorter expected         10 satisfied  shorter expected         8 

what best way answer following question: if responder answer q2 "much shorter expected", probability q3 10.

i'm looking explicit answers or how guides can learn in future. accomplish in excel or pandas.

can use logistic regression , assign dummy variable q2? can somehow create correlation matrix see how correlated responses of q2 q3?

you can calculate using formula:

=(countifs($b$2:$b$37,"much shorter expected",$c$2:$c$37,10)/countif($b42:$b$37,"much shorter expected"))*100

we give range b2:b37 check answer "much shorter expected"

when find it, check see if gave 10 q3.

then take number true on total number times answered "much shorter expected", multiply 100 , round 2 decimal places.

formula example:

formula

you can modify formula accept different parameters:

=(countifs($b$2:$b$37,e2,$c$2:$c$37,f2)/countif($b$2:$b$37,e2))*100

example2

and if you're wondering math calculate probability, here steps:

  1. define events , outcomes.
  2. divide number of events number of possible outcomes.
  3. multiply answer 100 make percent.
  4. use percentage answer.

http://www.wikihow.com/calculate-probability


Comments