Skip to content

Momentum ​

Price change over N bars.

Kind indicator · Drawn in its own pane

Try it ​

On the chart, press / and choose Momentum under Oscillators. To change it, copy the source below into the AlphaScript editor.

Inputs ​

InputTypeDefault
Lengthint10
Sourcesource"close"
Colorcolor"#2962FF"

Source ​

From packages/alphascript/indicators/momentum.as.js.

js
indicator({ name: "Momentum", shortTitle: "Mom", overlay: false });
const length = input.int("Length", 10, { min: 1 });
plot(ta.mom(input.source("Source", "close"), length), { title: "Mom", color: input.color("Color", "#2962FF", { group: "Style" }) });

AlphaScript language v0.1 · runtime 0.2.0