Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Slice
An operator form of Part
Contributed by:
Taliesin Beynon
ResourceFunction["Slice"][i,j,…][expr] gives expr[[i,j,…]]. |
Details and Options
ResourceFunction["Slice"] represents an operator form of Part.
Examples
Basic Examples (3)
Select the first element of a list using the operator form:
| In[1]:= |
| Out[1]= |
An operator that selects the key in an Association:
| In[2]:= |
Extract the value of a:
| In[3]:= |
| Out[3]= |
Extract the first two key/value pairs using the operator form:
| In[4]:= |
| Out[4]= |
Requirements
Wolfram Language 11.3 (March 2018) or above
Version History
- 1.0.0 – 04 February 2019
Related Symbols
License Information
This work is licensed under a Creative Commons Attribution 4.0 International License