Appearance
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
| Input | Type | Default |
|---|---|---|
| Length | int | 10 |
| Source | source | "close" |
| Color | color | "#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" }) });