Description Usage Arguments Details Value Examples

This function displays odds ratios and their normal confidence intervals.

1 | ```
odds(n11, n12, n21, n22, a = 0.05)
``` |

`n11` |
sample size for level 1.1 |

`n12` |
sample size for level 1.2 |

`n21` |
sample size for level 2.1 |

`n22` |
sample size for level 2.2 |

`a` |
significance level |

This statistic is the ratio between level 1.1 divided by level 1.2, and level 2.1 divided by 2.2. In other words, these are the odds of level 1.1 given level 1 overall versus level 2.1 given level 2 overall.

To calculate odds ratios, First, the sample size for level 1.1 is divided by the sample size for level 1.2. This value is divided by the sample size for level 2.1, after dividing by the sample size of level 2.2.

odds <- (n11 / n12) / (n21 / n22)

Learn more on our example page.

Provides odds ratios with associated confidence intervals and relevant statistics.

`odds` |
odds statistic |

`olow` |
lower level confidence interval of odds statistic |

`ohigh` |
upper level confidence interval of odds statistic |

`se` |
standard error |

`estimate` |
the oods statistic and confidence interval in APA style for markdown printing |

1 2 3 4 5 6 7 8 9 10 11 12 | ```
#A health psychologist was interested in the rates of anxiety in
#first generation and regular college students. They polled campus
#and found the following data:
#| | First Generation | Regular |
#|--------------|------------------|---------|
#| Low Anxiety | 10 | 50 |
#| High Anxiety | 20 | 15 |
#What are the odds for the first generation students to have anxiety?
odds(n11 = 10, n12 = 50, n21 = 20, n22 = 15, a = .05)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.