How to set 'PreserveVariableNames' to True while importing an Excel file into matlab?

82 ビュー (過去 30 日間)
I need it to keep the tables in the original format with spaces and non ASCII characters. I've read that this option is available in R2019b. But how to do it?

採用された回答

Fangjun Jiang
Fangjun Jiang 2020 年 1 月 14 日
help readtable
'PreserveVariableNames' Flag to preserve variable names, specified
as true or false. The default value is false. When
specified as true, MATLAB preserves variable names
that are not valid MATLAB identifiers such as variable
names that include spaces and non-ASCII characters.
  2 件のコメント
WalterWhite
WalterWhite 2020 年 1 月 14 日
I read the same in Docs. Can you write the syntax please?
Fangjun Jiang
Fangjun Jiang 2020 年 1 月 14 日
out=readtable('test.xlsx','PreserveVariableNames',true)

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSpreadsheets についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by