From 7dcd214a4d302ae1817ed1381c6f03b261c87c01 Mon Sep 17 00:00:00 2001 From: yoonthegoon <71526721+yoonthegoon@users.noreply.github.com> Date: Wed, 2 Aug 2023 10:07:20 -0400 Subject: [PATCH] add Dataset.get --- docs/tutorial.rst | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/tutorial.rst b/docs/tutorial.rst index 23f48280..e5cd12bc 100644 --- a/docs/tutorial.rst +++ b/docs/tutorial.rst @@ -167,7 +167,13 @@ You can slice and dice your data, just like a standard Python list. :: >>> data[0] ('Kenneth', 'Reitz', 22) + >>> data[0:2] + [('Kenneth', 'Reitz', 22), ('Bessie', 'Monke', 20)] +You can also access a row using its index without slicing. :: + + >>> data.get(0) + ('Kenneth', 'Reitz', 22) If we had a set of data consisting of thousands of rows, it could be useful to get a list of values in a column.