Arithmetic on Table Variables
Dot notation has been convenient for operations such as converting an existing table variable, adding
a new variable, assigning values, plotting, and applying functions like polyval to a table variable.
Dot notation is also convenient for arithmetic operations on table variables. For example, convert the
LotFrontage variable from feet to meters.
housing.LotFrontage = 0.3048 * housing.LotFrontage;
housing.Properties.VariableUnits("LotFrontage") = "m"
housing=2928×24 table
PID
MSSubClass
LotFrontage
LotAr
____________
_____________________________________________________
___________
_____
"0526301100"
1-STORY 1946 & NEWER ALL STYLES
42.977
3177
"0526350040"
1-STORY 1946 & NEWER ALL STYLES
24.384
1162
"0526351010"
1-STORY 1946 & NEWER ALL STYLES
24.689
1426
"0526353030"
1-STORY 1946 & NEWER ALL STYLES
28.346
1116
"0527105010"
2-STORY 1946 & NEWER
22.555
1383
"0527105030"
2-STORY 1946 & NEWER
23.774
997
"0527127150"
1-STORY PUD (Planned Unit Development) - 1946 & NEWER
12.497
492
"0527145080"
1-STORY PUD (Planned Unit Development) - 1946 & NEWER
13.106
500
"0527146030"
1-STORY PUD (Planned Unit Development) - 1946 & NEWER
11.887
538
"0527162130"
2-STORY 1946 & NEWER
18.288
750
"0527163010"
2-STORY 1946 & NEWER
22.86
1000
"0527165230"
1-STORY 1946 & NEWER ALL STYLES
19.049
798
"0527166040"
2-STORY 1946 & NEWER
19.202
840
9 Tables
9-78
Précédent

- 422/1450

Suivant