SPARKLINE
draws a mini line or bar chart from a range — options take charttype, color, negcolor, linewidth, ymin and ymax · from google sheets · no excel equivalent · sheets: differs in detail
signature
SPARKLINE(data, [options])
returns: svg
| argument | required |
|---|---|
| data | required |
| options | optional |
examples
formula and result, taken from the engine's own test suite — every result below is asserted in CI, not written by hand.
| A | |
|---|---|
| 1 | 10 |
| 2 | 20 |
| 3 | 30 |
| 4 | 40 |
fx
=SPARKLINE(A1:A4) related
- FROMBYTES converts byte array to integer
- GENERATEID generates unique ID with prefix and random suffix
- HASH hex digest of text: SHA256 (default, FIPS 180-4) or MD5 (RFC 1321)
- IMAGE shows an image from a url — the browser loads it, the engine does not fetch
- ISIN checks if value is in a range or comma-separated list
- RANDOMCHOICE random pick from a range (with replacement); count > 1 spills a column