Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
en:create:questions:random [28.07.2019 12:39]
urbanalgae [Application]
en:create:questions:random [30.07.2019 22:23] (current)
admin Update
Line 5: Line 5:
 The random generator developed from the [[:​en:​create:​random_urns|urn-function]] and ensures (like the urn) that all ballots are drawn equally (option //mode of drawing//). This is especially important when experimental groups have to be of equal size. Because an unrestricted random sampling could lead to massive deviations in group sizes (especially in case of smaller samples). The random generator developed from the [[:​en:​create:​random_urns|urn-function]] and ensures (like the urn) that all ballots are drawn equally (option //mode of drawing//). This is especially important when experimental groups have to be of equal size. Because an unrestricted random sampling could lead to massive deviations in group sizes (especially in case of smaller samples).
  
-The extensive examples in the chapter [[:​en:​create:​randomization]],​ concerning the use of filters for experimental stimuli, are also transferable to the random generator. This can be done by placing the random generator element on the questionaire page (instead of the operator ''​[[:​en:​create:​functions:​urndraw]]''​). The drawn Number ​can be subsequently ​retrieved via ''​[[:​en:​create:​functions:​value]]''​ (as described in the urn thread).+The extensive examples in the chapter [[:​en:​create:​randomization]],​ concerning the use of filters for experimental stimuli, are also transferable to the random generator. This can be done by placing the random generator element on the questionaire page (instead of the operator ''​[[:​en:​create:​functions:​urndraw]]''​). The code that was drawn can then be retrieved via ''​[[:​en:​create:​functions:​value]]''​ (as described in the urn thread). Either on the same page (below the random generator) and/or on any subsequent page of the questionnaire.
  
 **Hint:** If the random variation doesn’t work as desired, the debug-informations in the questionnaire will provide fast explanations. (Read more at [[:​en:​create:​filter-solving]].) **Hint:** If the random variation doesn’t work as desired, the debug-informations in the questionnaire will provide fast explanations. (Read more at [[:​en:​create:​filter-solving]].)
Line 13: Line 13:
  
   * For the second drawn ballot two kinds of values are available: first the numeric code and second the inscribed text for the ballot (e.g. the file name of a image, as seen in the example below)   * For the second drawn ballot two kinds of values are available: first the numeric code and second the inscribed text for the ballot (e.g. the file name of a image, as seen in the example below)
- 
   * The random generator can draw multiple ballots during one interview (option //Amount of ballots per interview//​) ensuring that no ballot can be drawn twice   * The random generator can draw multiple ballots during one interview (option //Amount of ballots per interview//​) ensuring that no ballot can be drawn twice
 +  * The random generator yields only one value (including it’s inscription) per ballot. Combinations are only possible using the following workaround: The combination is saved as an inscription and separated after the drawing using [[http://​php.net/​manual/​de/​function.explode.php|explode()]].
  
-  * The random generator yields only one value (including it’s inscription) per ballot. Combinations are only possible using the following workaround: The combination is saved as an inscription and separated after the drawing using [[http://​php.net/​manual/​de/​function.explode.php|explode()]]. 
  
 ===== Example: Varying screen-stimulus ===== ===== Example: Varying screen-stimulus =====
Line 127: Line 126:
 ===== Example: Show multiple images ===== ===== Example: Show multiple images =====
 In this example participants should rate 300 images. To achieve this each participant has to rate 20 different pictures - each on a different page. In this example participants should rate 300 images. To achieve this each participant has to rate 20 different pictures - each on a different page.
 +
 ==== Preperation ==== ==== Preperation ====
   * Upload all images to **Images and Media Data**   * Upload all images to **Images and Media Data**
Line 349: Line 349:
   * The last Page which belongs to stimulus B receives the ID “endB”.   * The last Page which belongs to stimulus B receives the ID “endB”.
   * The first Page of the final part (which follows directly to “endB”) receives the ID “final”.   * The first Page of the final part (which follows directly to “endB”) receives the ID “final”.
 +
  
 ==== Application ==== ==== Application ====
 +
 Under **Create a Questionnaire** drag and drop the random generator to the last page of the generic part. The following page should respectively have the ID „beginA“. Under **Create a Questionnaire** drag and drop the random generator to the last page of the generic part. The following page should respectively have the ID „beginA“.
  
Line 367: Line 369:
  
  
 +===== Readjust the Drawings =====
 +
 +If one works with many experimental groups, it is possible that the actually successful equal distribution is lost due to removals required by data cleaning. Especially if the number of cases per group is very small, the cases that have to be removed (e.g. as a result of the manipulation check) may cause a substantial tilt. Then it may be necessary to adjust the random number generator slightly during the survey.
 +
 +**Warning:​** The random selection should be readjusted __only__ if the participants are continuously recruited from the same population. Otherwise there is a danger of confounding:​ Imagine an experiment with 4 groups, in which the participants are all invited on a certain day. After two thirds of the participants have completed the questionnaire,​ one notices that a lot of cases in group 1 are invalid, and the random generator is readjusted. So from now on more participants will be assigned to group 1. Now there is a confounding,​ because participants who respond to an invitation later can systematically differ from participants who respond quickly. So the participants in group 1 would now differ a-priori from participants in other groups -- and thus differences in the dependent variables would no longer be solely due to the experimental stimulus.
 +
 +**Tip:** In a situation where you can't adjust the random drawing afterwards, you can use an [[:​en:​create:​random_urns|Urn]]] and configure ''​urnDraw()''​ to store the codes manually. The manual filing with ''​[[:​en:​create:​functions:​urnputaway]]''​ is done after checking with a [[:​de:​create:​filters|filter]] that the case is usable. Disadvantages:​ This is comparatively difficult and there can be considerably unequal group sizes especially at the beginning of the survey.
 +
 +If the conditions for readjustment (see above) are fulfilled, the procedure is as follows:
 +
 +  - The preliminary data set is cleaned up (dropout, missing answers, manipulation check, no consent to the use of the data, ...).
 +  - A frequency table of the random generator variable is created.
 +  - This frequency table is converted into a format ''​Code:​ Number''​ (see below).
 +  - This list is drawn into the field //drawn so far// in the random generator -- the order of the values does not matter, the only important thing is that code and number are contained.
 +  - After saving, the list is automatically sorted and further random draws are made in such a way that previous inequalities are compensated.
 +
 +The list of codes and usable cases can look like this:
 +
 +<​code>​
 +111111: 2
 +111211: 1
 +111311: 2
 +111411: 2
 +112111: 1
 +112211: 2
 +112311: 2
 +112411: 2
 +u.s.w.
 +</​code>​
 +
 +In Excel or OpenOffice Calc, such a list is created by combining the previously created frequency table (with codes, not labels) with the following function (if the codes are in column A and the frequencies are in column B):
 +
 +<code excel>
 +=CONCAT(A1; ": "; B1)
 +</​code>​
 +    ​
 +In GNU R you can output the frequency table and the list as follows (if the variable of the random generator is e.g. RG01):
 +
 +<code r>
 +tmp = table(data$RG01)
 +cat(paste(paste(names(tmp),​ tmp, sep=": "), collapse="​\n"​))
 +</​code>​
en/create/questions/random.txt · Last modified: 30.07.2019 22:23 by admin
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
Driven by DokuWiki