Skip to contents

Simple Moving Average (SMA)

Usage

sma(price, n)

Arguments

price

A numeric vector of prices

n

The period for SMA calculation

Value

A numeric vector containing the SMA values