Current Page:
NeXtMidas Training
Common Midas Concepts
Data Types
Lab 1 - Data Types
Exercises
|
|
- Lab 1 - Data Types:
- The following exercise is intended to show the different NeXtMidas data types. You can either type the
commands or copy/past the commands into your NeXtMidas session.
- Enter the following commands to create three tables. Note the values assigned to LABEL2.
nM> res two 2
nM> res mytable {label1=1,label2="two"}
nM> res mytable2 {label1=1,label2=two}
nM> res mytable3 {label1=1,label2=^two}
nM> res my* /all
T: MYTABLE = Table of 2 entries
L: LABEL1 = 1
3S: LABEL2 = two
T: MYTABLE2 = Table of 2 entries
L: LABEL1 = 1
3S: LABEL2 = TWO
T: MYTABLE3 = Table of 2 entries
L: LABEL1 = 1
L: LABEL2 = 2
- Create complex, vector and quad data types. Note that these types default to double unless cast to long, L:.
nM> res mycd (1.2,2.3)
nM> res myvd (1.0, 2.0,3.0)
nM> res myqd (4,3,2,1)
nM> res my* /all
CD: MYCD = (1.2,2.3)
VD: MYVD = (1.0,2.0,3.0)
QD: MYQD = (4.0,3.0,2.0,1.0)
nM> res L:myql (4,3,2,1)
nM> res myql
QL: MYQL = (4,3,2,1)
- Get current time. Note the format.
nM> timex now
Time = 2015:12:15::17:13:19.573
nM> timex ssm
Time = 17:13:58.516
|
|
|