【问题标题】:Writematrix command not working in MATLABWritematrix 命令在 MATLAB 中不起作用
【发布时间】:2020-08-23 17:01:16
【问题描述】:
sname='Sheet1';
startingColumn='A';
nextRow='1';
filename = 'C:\Users\vvb\Documents\New\ltp.xlsx';

 ltp_hist_uper=hist(ltp_uper,10);
 ltp_hist_lower=hist(ltp_lower,10);
 
 ltp_full=[ltp_hist_uper ltp_hist_lower]; % contatinate both uper and lower vectors
 range=sprintf('%s%d',startingColumn,nextRow);
writematrix(ltp_full,filename,sname,range);

我已下载此代码用于从音频文件中提取特征并将这些特征存储在 Excel 中的矩阵中,但 writematrix 命令引发错误,即参数名称无效:Sheet1。

【问题讨论】:

    标签: matlab signals acoustics


    【解决方案1】:

    前两个之后的“writematrix”函数的参数是名称-值对组合。在这种情况下,您应该能够通过以下方式继续满足您的要求:

    writematrix(ltp_full, filename,'Sheet', sname, 'Range',range);
    

    【讨论】:

    • 我的代码现在工作正常,但 xlsx 文件中的值没有按预期更新。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-05-08
    • 2015-05-20
    • 1970-01-01
    • 1970-01-01
    • 2014-04-01
    相关资源
    最近更新 更多