Как поменять столбец и строку в таблице (Транспонировать) в iWork Numbers?

19237
Saneef

Я хочу транспонировать таблицу (чередовать строки в столбцы и наоборот). Как это сделать в iWork Numbers.

8

2 ответа на вопрос

5
mariosangiorgio

I wrote a simple AppleScript that does it.

tell application "Numbers" activate tell the front document tell the first sheet set original_range to selection range of first table set orignal_table to first table set number_of_columns to column count of orignal_table set number_of_rows to row count of orignal_table set trasposed_table to make new table with properties repeat with i from 1 to number_of_columns repeat with j from 1 to number_of_rows tell orignal_table set original_value to the value of cell i of row j end tell tell trasposed_table set the value of cell j of row i to original_value end tell end repeat end repeat end tell end tell end tell 

Here you can find more details about it.

Стоит отметить, что эта формула принимает «значение» для ячеек, что означает, что если в ячейках, которые вы перемещаете, есть формулы, будет транспонирован только их вывод. Формул не будет. Nick Q. 11 лет назад 2
2
Ash

Those using the latest version of Numbers can use the "Transpose Rows and Columns" option under the "Table" menu, as seen in this answer over on StackExchange. Image below also shamelessly 'borrowed' from that answer, for easy reference.

Похожие вопросы