liveBook · Manning

Array

As explained in Data Without Labels

A matrix is a rectangular arrangement of values organized into rows and columns.

An array organizes values into a regular structure. A matrix is a rectangular array arranged in rows and columns, giving algorithms a numeric form on which mathematical and statistical calculations can operate. section 7.7 section 1.2.2

Arrays connect raw data to machine learning representations. Image pixels can be stored as matrix values, while text words can be encoded as binary vectors. One-hot encoding illustrates the idea, but large vocabularies create sparse, high-dimensional matrices that are expensive to process. section 7.7 section 1.2.2

Encoding words as vectors

For “It is raining heavily,” lowercase the words, sort them as heavily, is, it, raining, and assign positions 0 through 3. The word “it” becomes [0, 0, 1, 0], while “heavily” becomes [1, 0, 0, 0]. section 7.7

Figure 1.4 An example of how unstructured data can be represented as a matrix to analyze. The matrix on the right is only an illustration and not the actual numbers.
figure

Use the illustration to connect an image region with its matrix representation. section 1.2.2

How Data Without Labels covers it

How deep it goes
Defines rectangular organization and demonstrates binary-vector encoding, but stops short of detailed array operations or implementation code.
Examples
Uses binary word vectors and an illustrated vacuum-cleaner image region represented as a matrix.
What it assumes
Assumes familiarity with data types and binary values while introducing row-column organization and numeric encoding.
What you can do after
Apply matrix representations to encode text and image data for algorithmic analysis.
How it connects
Connects matrices with one-hot encoding, text representation, image data, unstructured data, and deep learning.

Also explained in

Compare how 40 books explain array →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Data Without Labels. The section links point to the parts of the book it draws on.