TOCOL Function in Google Sheets

Convert an array into a single column using the TOCOL function.

TOCOL Function

The TOCOL function in Google Sheets converts an array or range into a single column.

Syntax

TOCOL(array_or_range, [ignore], [scan_by_column])
  • array_or_range: The array or range to convert.
  • ignore (optional): Specify values to ignore. By default, no values are ignored.
  • scan_by_column (optional): If TRUE, the function scans values by column first.

Examples

  1. Basic Conversion

Convert the array in A1:C3 into a single column:

=TOCOL(A1:C3)
  1. Ignoring Zeros

Convert the array and ignore zeros:

=TOCOL(A1:C3, 0)
  1. Scanning by Column

Convert and scan by column:

=TOCOL(A1:C3, , TRUE)

Notes

  • Useful for flattening arrays for further data analysis or visualization.
  • TRANSPOSE: Transpose rows and columns of an array or range.
  • TOROW: Convert an array or range into a single row.