Learn R Programming

matlab (version 0.7-6)

std: MATLAB std function

Description

Computes the standard deviation of the values of x.

Usage

std(x, flag = 0)

Arguments

x
numeric vector or matrix
flag
integer logical. If 0, selects unbiased algorithm. If 1, selects biased algorithm (currently unsupported).

Value

  • Return value depends on argument x. If vector, returns the standard deviation. If matrix, returns vector containing the standard deviation of each column.

Details

Simply invokes stats::sd.

Examples

Run this code
std(1:2) ^ 2

Run the code above in your browser using DataLab