2014-01-25 62 views
0

我是系統Wolfram Mathematica 9.0中的新成員,我想用水平方法創建表。而且我只做了垂直的。現在,我會告訴你:Wolfram Mathematica 9.0生成垂直表

Here is the output+ code

+2

試試'TableForm [{{4,16},{3,5}},TableHeadings - > {{「x」,「y」},None}]'。 –

回答

2

你沒有表明所產生的不需要的輸出輸入,但我相信它是這樣的:

xx = {4, 16}; 
yy = {3, 5}; 

TableForm[{{xx}, {yy}}, TableHeadings -> {{"x", "y"}, None}] 

爲了得到你的願望,你的輸出只需要在每個表達式周圍省略括號外的一組List。因爲這是推斷的,您也可以省略None

TableForm[{xx, yy}, TableHeadings -> {{"x", "y"}}] 

enter image description here

您也明確與TableDirections指定方向:

TableForm[{{xx}, {yy}}, 
    TableHeadings -> {{"x", "y"}}, 
    TableDirections -> {Column, Row, Row} 
] 

這前面我的答案說明的方式,TableForm格式嵌套的列表:

https://stackoverflow.com/a/5011242/618728

+0

非常感謝! :) –

+1

@加里不客氣。如果您有更多問題,我建議您在[Mathematica.SE](* Mathematica *專用的Stack Exchange站點)上提問。 –