You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -124,22 +124,22 @@ You can see that DataStock stores the relationships between each array and each
124
124
Specifying explicitly the references is only necessary if there is an ambiguity (i.e.: several references have the same size, like nx and nt2 in our case)
<imgalign="middle"src="https://github.com/ToFuProject/datastock/blob/devel/README_figures/DataStock_Obj.png"width="600"alt="Direct 3d array visualization"/>
@@ -168,31 +168,31 @@ st
168
168
DataStock also provides built-in object selection method to allow return all
169
169
objects matching a criterion, as lits of int indices, bool indices or keys.
170
170
171
-
```
172
-
In [9]: st.select(which='campaign', index=2, returnas=int)
171
+
``
172
+
In [9]: coll.select(which='campaign', index=2, returnas=int)
173
173
Out[9]: array([2])
174
174
175
175
# list of 2 => return all matches inside the interval
176
-
In [10]: st.select(which='campaign', index=[2, 4], returnas=int)
176
+
In [10]: coll.select(which='campaign', index=[2, 4], returnas=int)
177
177
Out[10]: array([2, 3, 4])
178
178
179
179
# tuple of 2 => return all matches outside the interval
180
-
In [11]: st.select(which='campaign', index=(2, 4), returnas=int)
180
+
In [11]: coll.select(which='campaign', index=(2, 4), returnas=int)
181
181
Out[11]: array([0, 1])
182
182
183
183
# return as keys
184
-
In [12]: st.select(which='campaign', index=(2, 4), returnas=str)
184
+
In [12]: coll.select(which='campaign', index=(2, 4), returnas=str)
185
185
Out[12]: array(['c0', 'c1'], dtype='<U2')
186
186
187
187
# return as bool indices
188
-
In [13]: st.select(which='campaign', index=(2, 4), returnas=bool)
188
+
In [13]: coll.select(which='campaign', index=(2, 4), returnas=bool)
0 commit comments