From: Roman Y. <Ro...@ss...> - 2003-11-06 10:38:22
|
I've done some work on this issue before. This is how I did it: 1. Added [value] filed on the question design page for each question_choice. 2. Stored it in the question_choice value field. Stared adding some reporting functionality, but had to switch my focus to something else. Haven't implemented anything for CSV export, but can probably get to it now. Please let me know if you think it is the way to do it (set 1 and 2). All the best, Roman -----Original Message----- From: Roman Yashin [mailto:Ro...@ss...] Sent: Thursday, November 06, 2003 12:06 PM To: php...@li... Subject: RE: [phpesp-dev] CVS export possible bug I think I found it! (Haven't fixed it yet tho'). It's in espresponse.inc, response_select_name() function. The problem is in returning $nam array (see line ~651). It's being created couple of lines before with $nam[$key] = $val. I've done the following tests: First: count ($nam,COUNT_RECURSIVE) for $nam[$key] = $val // where $key = question name/label Second: count ($nam,COUNT_RECURSIVE) for $nam[] = $val // notice no variable for index The two arrays have different size, which I believe is incorrect. BTW, the second array has correct data for CSV export. Something happens when we use question names for indexes in the array. I hope all these make sense. I am afraid this behavior might surface somewhere else. James, Kon and others I don't know: What do you guys think about it? Cheers, Roman -----Original Message----- From: Roman Yashin [mailto:ro...@ss...] Sent: Monday, November 03, 2003 7:06 PM To: Matthew Gregg Cc: php...@li... Subject: Re: [phpesp-dev] CVS export possible bug Matthew, I know of Rank type behavior, I'm not talking about that. In my case, I am suing Radio Buttons and only two out of 50+ questions getting messed up! Thanks for your help tho' Roman On Monday, November 3, 2003, at 06:10 PM, Matthew Gregg wrote: > Your problem might be related to this bug: > http://sourceforge.net/tracker/ > index.php?func=detail&aid=827824&group_id=8956&atid=108956 > > Try taking that "off by one" bug into account and see if the > frequencies > work out. > > On Mon, 2003-11-03 at 10:08, Roman Yashin wrote: >> Hi, >> >> >> >> I think there is a possible bug in CSV export function. There is >> always a chance that my dataset is messed up, but I don't think so. >> I'm doing more tests to eliminate that possibility. Meanwhile, has >> anyone experience the following: >> >> >> >> The frequencies for question choices on the report page DO NOT >> correspond to the frequencies for the same question when you analyze >> it in SPSS or Excel? >> >> >> >> Example: >> >> Question: I believe there could a bug in CSV Export function. >> >> >> >> In ESP Report you get: >> >> Strongly Agree 8.8% (13) >> >> Agree 59.9% (88) >> >> Disagree 29.9% (44) >> >> Strongly Disagree 1.4% (2) >> >> TOTAL 100.0% 147 >> >> >> >> In CSV file you get (SPSS and Excel): >> >> Strongly Agree (16) >> >> Agree (78) >> >> Disagree (52) >> >> Strongly Disagree (1) >> >> TOTAL 100.0% 147 >> >> >> >> I should've probably made sure it is a bug before bothering you all, >> but I figured if somebody has experienced something similar it will >> save me a great deal of time. >> >> >> >> Cheers, >> >> >> >> Roman >> >> > -- > mcg > ------------------------------------- > The IT Lab (http://www.itlab.musc.edu) ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ _______________________________________________ phpESP-devel mailing list php...@li... https://lists.sourceforge.net/lists/listinfo/phpesp-devel |