how to export results of "gpdemo3" to excel?

1 回表示 (過去 30 日間)
Anuj Gulati
Anuj Gulati 2020 年 9 月 21 日
編集済み: Aman Vyas 2020 年 10 月 9 日
Hello,
I am using GPTIPS package to create a symbolic regression model.
I am using its "gpdemo3" example.
I want all my results to be exported to excel .
Please Help

回答 (1 件)

Aman Vyas
Aman Vyas 2020 年 10 月 9 日
編集済み: Aman Vyas 2020 年 10 月 9 日
Hi,
From my understanding it seems you are getting your output in num or str format. You can first use the below function to convert your output to sym.
function y=xsym(x)
if isnumeric(x)
x=num2str(x);
end
y=str2sym(x);
Then add the code below:
if~verLessThan('matlab','9.3');sym=@xsym;end
Once you have symbolic expression available you can use
char(sym)
Since no data is available, i am not completely sure this should work, but its a possible workaround.
Hope it helps !

カテゴリ

Help Center および File ExchangeData Import from MATLAB についてさらに検索

タグ

製品


リリース

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by