This Gist is there to help you creating a Sankey Diagram from your Google Spreadsheets.
- Open a spreadsheet
- Click "Tools" -> "Scripts"
- create the two files
code.gs
andindex.html
- insert the document ID from the URL on line 10,
code.gs
- select which sheet is the base for the sankey diagram
- the layout of the table should be as shown in the Example Spreadsheet
- Open the same document
- Click "Zusatzfunktionen" -> "SankeyDiagram"
https://docs.google.com/spreadsheets/d/1IUmvhYuuBvfYEu8OfDczmW6LQW-xaeh5c6rklOg3x-o/
@jaredstein I got the same error. I believe the column indices in this message are 0-based. In my case, I had added a 4th column (unrelated to the Sankey data) which did contain some non-numbers. I fixed the error by using
getRange(1, 1, sheet.getLastRow(), 3)
instead ofgetDataRange
, i.e. forcing the script to only look at the first 3 columns.