項目 | サンプル | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
列名を取得したい |
|
|||||||||||||||||||
テーブルから1列取得したい |
|
|||||||||||||||||||
テーブルから複数列取得したい |
|
|
=> |
|
table("C1","C2","C3","C4","C5") = cbind(1,"C2",3,"C4","C5");
//
result = titles(table);
|
=> |
|
N = 4;
c1("C1") = {1:N};
c2("C2") = rep("a",N);
table = cbind(c1,c2);
//
colIndex = 2;
result = table(colIndex);
colName = "C2";
result = table(colName);
|
=> |
|
table("C1","C2","C3","C4","C5") = cbind(1,"C2",3,"C4","C5");
//
result = table(1,3);
keyList = {1,3}; idxList = {1:ncol(table)}; result = table(sel(belong(idxList,keyList),idxList));