Just Another Statistics Textbook
  • Report an error
  • Request a clarification
  • Suggest Content

Formulas

  • Welcome
    • About
    • Installing R(Studio)
  • R Basics
    • Types of Scripts
    • R Fundamentals
    • R Logic
  • Statistics Foundations
    • Statistics Basics
    • Scientific Notation
    • Probability (R)
  • Describing Data
    • Central Tendency (R, Python, Excel, JASP)
    • Dispersion (R,Python, Excel, JASP)
  • Distributions
    • Binomial Distribution (R)
    • Normal Distribution
    • Skewness (R,Python)
    • Transforming Data (R)
  • Correlation
    • Correlations (R,Python)
    • Partial Correlations (R,Python)
  • Regressions
    • Simple regression (R)
    • Multiple Regressions (R)
  • General Linear Models
    • General Linear Models and Sum of Squares (R, Python)
    • T-Tests (R, Python incomplete)
    • One Way ANOVA (incomplete)
    • Repeated Measures ANOVAs
    • Mixed ANOVA (incomplete)
    • ANCOVA (incomplete)
  • Categorical
    • Contingency (R)
  • Item analyses
    • Cronbach’s Alpha (R,Python)
  • Multiple testing
    • Family-Wise Error (R)
    • False Discovery Rate(R)
    • FWER, FDR, Positive and Negative effects(R)
  • Permutations
    • Permutations (R)
    • Permutation vs. t tests (incomplete)
  • Excel tutorial
    • Formulas
    • If function
    • Count and countifs function
    • Sum and SumIf
    • Averageifs
    • Anchoring
  • Test yourself
    • All questions
    • Question Maker

On this page

  • Your turn

Formulas

The spreadsheet this worksheet is based on can be downloaded from here.

By using formulas we can automate a lot of processing in excel.

All you need to do to make a cell a formula, is to put an “=” sign at the start of it.

Let’s start by going to the worksheet Formulas (you might already be there, or need to scroll left in the tabs at the bottom of the page):

You’ll see that there’s a hypothetical situation in which someone has done two runs, and wants to calculate the total distance they’ve run. We can use the following formula to add the values in each of the cells together:

You can see that you can just add cell B2 to cell B3 to get the total added together.

Your turn

Do this yourself, and complete the following:

The total distance run was…

viewof question_0_response = Inputs.number([0,100], {label: "", step:.01});
correct_q0 = 33.37;

question_0_result = { 
  if(question_0_response == correct_q0){
    return "Correct!";
  } else {
    return "Missing or incorrect."
  } 
}

Now let’s use this logic to work out some other values on that sheet:

The total distance run by James was…

viewof question_1_response = Inputs.number([0,100], {label: "", step:.0005});
correct_q1 = 58.3535;

question_1_result = { 
  if(question_1_response == correct_q1){
    return "Correct!";
  } else {
    return "Missing or incorrect."
  } 
}

Elaine ran…

viewof question_2_response = Inputs.number([0,100], {label: "", step:.333});
correct_q2 = 16.333;

question_2_result = { 
  if(question_2_response == correct_q2){
    return "Correct!";
  } else {
    return "Missing or incorrect."
  } 
}

The total distance run by Dianna was…

viewof question_3_response = Inputs.number([0,100], {label: "", step:.002});
correct_q3 = 32.184;

question_3_result = { 
  if(question_3_response == correct_q3){
    return "Correct!";
  } else {
    return "Missing or incorrect."
  } 
}

Feel free to play around with these formulas a bit more. A really good way to learn excel is to play around with what you’ve learned to build up confidence with it.