Section author: Laiton Hedley
List of Functions
Use these functions in the formula editor to create computed variables, transformed variables, and filters.
Understanding Formulas
Build your formulas using numbers, variable names, text values, operators, and functions.
Numbers: Enter whole numbers or decimals as-is (e.g.,
1,2.5).Variable names: Type the name of an existing column (e.g.,
variable_name).Text values: Wrap text in single quotes (e.g.,
'Yes','Group A').Operators: Use arithmetic operators (
+,-,*,/) or logical operators (and,or).
Tip
If a variable name contains spaces, wrap it in backticks so jamovi can parse it correctly (e.g., use `reaction time`).
Row vs. Variable Functions
Many functions come in two versions:
Row functions (e.g.,
MEAN): Use these to calculate a result for each row individually.Variable functions (e.g.,
VMEAN): Use these to perform a calculation using every value in a column.
For more detail on this distinction, see Row and V Functions.
Math Functions
Function |
Description |
|
|---|---|---|
|
Calculate the absolute value of each number in the column. |
|
|
Raise e to the power of each value in the column. |
|
|
Calculate the natural logarithm (base e) of each value. |
|
|
Calculate the base-10 logarithm of each value. |
|
|
Calculate the square root of each value. |
Statistical Functions
Function |
Description |
|
|---|---|---|
|
Calculate the average absolute deviation of values from the median. |
|
|
Calculate the absolute z-score for each value. |
|
|
Apply a Box-Cox transformation to the variable. |
|
|
Round up each value to the nearest whole number. |
|
|
Round down each value to the nearest whole number. |
|
|
Identify if a value is within the “box” (0) or outside the “whiskers” (> 1.5). |
|
MAX(...)VMAX(...) |
Find the highest value in a row ( |
|
|
Find the maximum absolute interquartile range across multiple variables. |
|
|
Find the maximum absolute z-score across multiple variables. |
|
MEAN(...)VMEAN(...) |
Calculate the average of a row ( |
|
MIN(...)VMIN(...) |
Find the lowest value in a row ( |
|
|
Assign an ordinal rank to each value in the column. |
|
|
Round each value to n decimal places. |
|
|
Normalize a set of numbers (shorthand for |
|
STDEV(...)VSTDEV(...) |
Calculate the standard deviation of a row ( |
|
SUM(...)VSUM(...) |
Add up all values in a row ( |
|
|
Calculate the median absolute deviation of a variable. |
|
|
Calculate the robust median absolute deviation of a variable. |
|
|
Find the median of a variable. |
|
|
Find the most common value (mode) in a variable. |
|
|
Return the number of non-missing cases in a variable (sample size). |
|
|
Calculate the standard error of a variable. |
|
VAR(...)VVAR(...) |
Calculate the variance of a row ( |
|
|
Standardize values into z-scores. |
Logical Functions
Function |
Description |
|
|---|---|---|
|
If the condition is true, use val; otherwise, use else. |
|
|
Use val if the cell is empty; otherwise, use else. |
|
|
Invert a boolean value (True becomes False, and vice versa). |
Text Functions
Function |
Description |
|
|---|---|---|
|
Check if a specific string (the needle) exists in a variable (the haystack). |
|
|
Split a text string by a specific character and return the text at a given position. |
|
|
Convert numeric values into text format. |
|
|
Convert text strings into numeric values, if possible. |
Date and Time Functions
Function |
Description |
|
|---|---|---|
|
Convert a text date (e.g., 2000-12-20) into the number of days since 1 Jan 1970. |
|
|
Convert a Unix day count back into a formatted date string. |
Reference Functions
Function |
Description |
|
|---|---|---|
|
Retrieve values from specific rows using a provided index. |
|
|
Find the row index of the first value that matches your criteria. |
Miscellaneous Functions
Function |
Description |
|
|---|---|---|
|
Count the number of non-missing values in a set of columns. |
|
|
Return only the values in a column that meet a specific condition. |
|
|
Strip the fractional component from a number to make it an integer. |
|
|
Shift the data in a column up or down by n rows. |
|
|
Fill a column with the current row number. |
|
|
Draw a random sample of n values from a variable. |
|
|
Return the total number of rows in a variable. |
Simulation Functions
Function |
Description |
|
|---|---|---|
|
Draw random samples from a Beta distribution. |
|
|
Draw random samples from a Gamma distribution. |
|
|
Draw random samples from a Normal (Gaussian) distribution. |
|
|
Draw random samples from a Uniform distribution. |