Accessors and Operations

Introduction

Having learned about how sparse data can be represented as SparseArray objects in pandas, let’s now look at the accessors and operations we can apply to these sparse arrays. We’ll look at the sparse dataset of movie ratings scored between 1 and 5 by different viewers, where NaN means that the movie isn’t rated yet:

Get hands-on with 1400+ tech skills courses.