0

Per Google Docs Editors Help > Using arrays in Google Sheets:

Any function that takes a range (e.g. A1:B6) as an input parameter will also accept an array in its place. For example, SPARKLINE takes a range as the first parameter to specify the values to plot.

I am trying to reference a cell that contains array values to use as the data parameter for a sparkline. My incoming data is in the format e.g. {43;12;98;2} and let's say it's placed in cell A1.

Direct inclusion of the values works just fine: =sparkline({43;12;98;2})

But this fails: =sparkline(A1) as does removing the curly brackets from A1 and doing this =sparkline({A1})

So how exactly does one reference another cell with an array of values in it?

0

So how exactly does one reference another cell with an array of values in it?

Assuming that the above statement should be read literally, that isn't possible. The alternative is to use the reference of the cells occupied by {43;12;98;2}, so if A1 has the following formula:

={43;12;98;2}

then the sparkline formula to use is

=sparkline(A1:A4)

NOTES: Despite that INDIRECT convert a TEXT value to a reference, Google Sheets built-in functions can't read formulas from other cells and can't evaluate a TEXT value as a formula.

  • Think you meant A1:A4. Seems odd this functionality is lacking, but understand it's not possible. Thanks – Dylan Aug 14 at 11:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.