A) Chi-square test of independence (two (or more) categorical descriptions).
B) Correlation analysis (Regression) to test for a relationship between two continuous variables.
C) The unpaired t-test compares the mean of one sample set against the mean of another sample set.
D) The paired t-test compares the means of two samples in which each datum in the first set can be matched with a corresponding datum in the second set (often the same individual measured before and after an experimental manipulation).
During training, you fought crayfish that are not size matched.
The answers to these questions are all predictions about a staged fight. These results may support hypotheses that are related to the adaptive value of different aspects of agonistic behavior. You will need to use the class dataset. In most cases you will want to use data from the first training fight rather than subsequent training fights. (Why do I suggest this?)
Which test would you use to address each of the following questions?
1) (A) Was the type of fight independent of which animal would tailflip first?
A) Chi-square test of independence (two (or more) categorical descriptions).
One Nominal Variable is type of fight (Winners training vs Losers training).
The other Nominal Variable is who tailflipped first (opponent vs. focal).
You will look at training fights only (not size matched)
You may want to set a criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
Or
You may want to set a criteria to include all training fight to increase your sample size.
Click Criteria / New
Double click “fight type?”
Double click “? IS NOT ?”
Double click experimental
Name this criteria “all training”
For the Chi-square test
While the Criteria is set to first training or all training
Click Analyze / New View
Choose Contingency table / and while holding down the apple key click Summary Table / Observed Frequencies / Expected Values.
Click Create Analysis
Then select Coded raw data.
Click OK.
In the Variables menu
Add type of fight and first tailflip.
The summary table includes the Chi-square P-value. (This should be included in the writeup.)
The Observed Frequency table includes the tally of your data (This should be included in the writeup)
The Expected Frequency table includes the values that you would have expected if these two variables were independent (i.e. if the null hypothesis was true).
Explain your choice of criteria.
2) (B) Was there a relationship between the opponent weight and the duration between first contact and tailflip?
B) Correlation analysis (Regression) to test for a relationship between two continuous or ordinal variables.
One Variable is the weight of the opponent
The other Variable is the duration to between first contact and first tailflip
You will look at training fights only (not size matched)
Set criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
Or
You may choose to look at other training fights. Adjust your criteria accordingly.
While the Criteria is set to first training
Click Analyze / Nonparametrics and choose Spearman Correlation
In the Variables window Double Click opponent wt (g)
Double Click duration (s) 1st contct t….
Click OK
As with ANOVA and t-tests that you have seen before, the P-value tells you if the relationship between your two variables is significantly different than would be expected by random chance. Ignore the Tied P-value for now.
To graph your data:
Remove any variable selections that are currently in the Variable menu.
Select Bivariate Plots/ Scattergram
Click Create Analysis
Display a line for the Regression, but do NOT check mean or slope.
Assign opponent wt (g) to be the X Variable by selecting it in the Variables menu and Click X Variable
Assign duration (s) 1st contct t…. to be the Y Variable by selecting it in the Variables menu and Click Y Variable
3) Was there a relationship between the focal animal's weight and the highest score in the battle (escalation)?
B) Correlation analysis (Regression) to test for a relationship between two continuous or ordinal variables.
One Variable is the weight of the focal animal
The other Variable is the highest score for the fight
You will look at training fights only (not size matched)
Set criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
Or
You may choose to look at other training fights. Adjust your criteria accordingly.
While the Criteria is set to training only
Click Analyze / Nonparametrics and choose Spearman Correlation
In the Variables window Double Click focal wt (g)
Double Click highest score
Click OK
As with ANOVA and t-tests that you have seen before, the P-value tells you if the relationship between your two variables is significantly different than would be expected by random chance. Ignore the Tied P-value for now.
To graph your data:
Remove any variable selections that are currently in the Variable menu.
Select Bivariate Plots/ Scattergram
Click Create Analysis
Display a line for the Regression, but do NOT check mean or slope.
Assign focal wt (g) to be the X Variable by selecting it in the Variables menu and Click X Variable
Assign highest score to be the Y Variable by selecting it in the Variables menu and Click Y Variable
4) Was the outcome of the fight independent of type of fight? (if it is, we aren't doing a very good "training")
A) Chi-square test of independence (two (or more) categorical descriptions).
One Nominal Variable (categorical) type of fight (Winners training vs Losers training)
The other Nominal Variable is who won (winner?). (opponent vs. focal)
You may want to look at all training fights only (not size matched)
Set criteria to focus on fights which are NOT experimental fights.
Click Criteria / New
Double click “fight type?”
Double click “? IS NOT ?”
Double click experimental
Name this criteria “training”
Or
Set criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
For the Chi-square test
While the Criteria is set to training or first training
Click Analyze / New View
Choose Contingency table / and while holding down the apple key click Summary Table / Observed Frequencies / Expected Values.
Click Create Analysis
Then select Coded raw data.
Click OK.
In the Variables menu
Add type of fight and winner?.
The summary table includes the Chi-square P-value. (This should be included in the writeup.)
The Observed Frequency table includes the tally of your data (This should be included in the writeup)
The Expected Frequency table includes the values that you would have expected if these two variables were independent (i.e. if the null hypothesis was true).
In your write up, justify your choice of criteria.
5) Is there a difference in the mean Total Behavior Score for focal crayfish in winner and loser training?
C) The unpaired t-test compares the mean of one sample set against the mean of another sample set.
The Nominal (categorical) grouping variable is type of fight (Winners training vs Losers training).
The Continuous Variable for which you want to test the mean is focal Total behavioral score
Set criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
(note: you may choose to look at all, or other training fights, if so, specify your criteria
accordingly and explain your choice.
With the Criteria set to first training
From the Analyze menu select New View
Double Click Unpaired Comparisons to create this analysis
Check the box for Unpaired t-test
Leave Hypothesized difference: 0
Leave Tail: Both
Click OK
In the Variable menu select type of fight and click Add to make this your grouping (nominal) variable.
In the Variable menu select focal Total behavioral score to make this your continuous variable.
To make your graphs, you will use Cell Plot->Point Chart to plot the two means with 95% Confidence Intervals. While the t-test tables are still selected, Point Chart will use the same two variables already selected.
IF YOU ARE INTERESTED TO LOOK AT THE OPPONENTS INSTEAD SIMPLY CHOOSE opponent Total behavioral score
IF YOU ARE INTERESTED TO COMBINE BOTH FOCAL AND OPPONENT ANIMALS IT WILL TAKE SOMETHING A BIT MORE COMPLICATED.
You will need to stack focal and opponent total behavior scores, probably in a new datasheet.
6) (C) Is there a difference in the Total Behavior Score for the opponent crayfish for the 3rd training fight compared to the 1st training fight?
C) The unpaired t-test compares the mean of one sample set against the mean of another sample set.
The Nominal (categorical) grouping variable is size class for which you use fight number? (1st training vs 3rd training).
The Continuous Variable for which you want to test the mean is opponent Total behavioral score
NOTE THIS IS UNPAIRED BECAUSE THE OPPONENTS WERE NEW INDIVIDUALS EACH TIME.
Set criteria to focus on the first and third training fight.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Click back in the Criteria definition box to get your Boolean operators
Double click ? OR ?
Double click third training fight
Name this criteria “first or third training”
From the Analyze menu select New View
Double Click Unpaired Comparisons to create this analysis
Check the box for Unpaired t-test
Leave Hypothesized difference: 0
Leave Tail: Both
Click OK
In the Variable menu select fight number? and click Add to make this your grouping (nominal) variable.
In the Variable menu select opponent Total behavioral score to make this your continuous variable.
To make your graphs, you will use Cell Plot->Point Chart to plot the two means with 95% Confidence Intervals. While the t-test tables are still selected, Point Chart will use the same two variables already selected.
*7) Was there a relationship between the weight difference of the two individuals and the time between first contact and tailflip? *(You would have to add a column to the data table and use a dynamic formula in order to calculate the size difference between the focal and opponent animals.)
B) Correlation analysis (Regression) to test for a relationship between two continuous variables.
One Variable is the weight difference between animals (needs to be calculated)
The other Variable is the highest score for the fight
You will look at training fights only (not size matched)
Set criteria to focus on the first training fight to avoid the confounding factor of experience.
Click Criteria / New
Double click “fight number?”
Double click “? IS ?”
Double click first training
Name this criteria “first training”
You must create a new column to calculate the weight difference:
Choose Manage
Select Formula
Double Click focal wt (g) from the dataset order
Click the minus sign
Double Click opponent wt (g) from the dataset order
Click the Attributes button to Name the column weight difference and restrict decimal places to 2
Click OK
Click Compute
While the Criteria is set to first training
Click Analyze / Nonparametrics and choose Spearman Correlation
In the Variables window Double Click weight difference
Double Click duration (s) 1st conta…
Click OK
As with ANOVA and t-tests that you have seen before, the P-value tells you if the relationship between your two variables is significantly different than would be expected by random chance. Ignore the Tied P-value for now.
To graph your data:
Remove any variable selections that are currently in the Variable menu.
Select Bivariate Plots/ Scattergram
Click Create Analysis
Display a line for the Regression, but do NOT check mean or slope.
Assign weight difference to be the X Variable by selecting it in the Variables menu and Click X Variable
Assign duration (s) 1st conta… to be the Y Variable by selecting it in the Variables menu and Click Y Variable
8) (D) Is there a difference in the Total Behavior Score for the focal crayfish for the 3rd training fight compared to the 1st training fight for the focal crayfish in loser’s training?
D) The paired t-test compares the means of two samples in which each datum in the first set can be matched with a corresponding datum in the second set (often the same individual measured before and after an experimental manipulation).
The two Continuous Variables for which you want to test the mean are
the focalTotal behavioral score for the 1st training
and focalTotal behavioral score for the 3rd training
NOTE YOU USE A PAIRED TEST BECAUSE THIS IS MEASUREMENT OF THE SAME FOCAL ANIMAL
Paired t-test: used when multiple response variables are measured for each individual
Unfortunately StatView is expecting the two paired continuous variables to be on the same line and this is not how we have set up our data sheet template.
You would have to sort by animal ID
Copy and Paste Transpose the Total Behavior Scores (once for each focal animal) into a new data template so that your data looked like:
IDFight1 Fight2fight3experimental
A1 ####
B1####
C1####
…
Analyze-> New View
Paired Comparisons
Paired t-test
Hypothesized difference: 0
Tail: BothOK
Assign Fight1 as your first continuous variable by selecting it in the Variables menu and clicking the Add button
Assign Fight3 as your second continuous variable by selecting it in the Variables menu and clicking the Add button.
You would make your graphs using Cell Plot->Point Chart to plot the two means with 95% Confidence Intervals. While the t-test tables are still selected, Point Chart will use the same two variables already selected.
In the Experimental fight, the crayfish were size matched.
You can test a hypothesis about the value of previous experience in agonistic encounters. If fight outcome is not independent of past experience, you would predict that the crayfish with “winner’s” training will win. You can also ask many questions concerning specific aspects of the fight (duration, intensity, specific behaviors etc.). Again, the type of data that you need to use to answer these questions will determine what statistical test you should use.
IN CLASS) (A) Was the experimental fight outcome independent of previous experience (winner’s training vs. loser’s training)?
A) Chi-square test of independence (two (or more) categorical descriptions).
REMEMBER THAT WE ENTERED THE DATA SO THAT THE FOCAL ANIMAL IN THE EXPERIMENTAL FIGHT WAS THE ONE THAT HAD HAD WINNER’S TRAINING
THIS ONE NEEDS A CHI SQUARE TEST FOR GOODNESSS OF FIT TO 0.5
Since there are only 6 experimental fights in the lab we need all 6 to perform as predicted in order to get statistical significance and even then the p=0.041 (not great)
If we include both rooms and have 12 animals and get 10 winners win with 2 losers losing we get a p=0.043.
From the Manage menu choose Formula
In the user function list, double-click “oneGroupChiSquare(?,?,?)
From the VariableList, assign to the first argument a continuous variable containing the observed counts
2 cells must be filled: # of times the winner training (focal) won
# of times the loser training (opponent) won
From the VariableList, assign to the second argument a continuous variable containing the expected counts
2 cells must be filled: # = one half of total fights recorded (omit any with tie)
# = one half of total fights recorded (omit any with tie)
To compute the chi-square statistic, type ……
WE WILL DO THIS ONE IN CLASS
1) Was the mean behavioral score for the focal animal different for fights that were won by that animal?
C) The unpaired t-test compares the mean of one sample set against the mean of another sample set.
The Nominal (categorical) grouping variable is whether the fight was won by the focal animal (winner? )