필터 지우기
필터 지우기

How to fix the error: data must contain only individual strings or scalar values?

조회 수: 1 (최근 30일)
Hi,
I have a problem with my output. My function gives me the following out put: [out1,qc1,teststat,pval]. Where teststat and pval are single numbers. Out1 and qc1 gives me as output [0,856981550219655;0,821247396820271]and [0;0], respectively.
I would like to export my results to excel, but if I use: xlswrite(filename,A,sheet,xlRange),
it does only export the values for teststat and pval. Same applies to my attempt to display the outputs in a table. Then I receive following error: ??? Error using ==> displaytable at 353 each cell in cell array ddata must contain only individual strings or scalar values.
How can I adjust out1 and qc1 to be able to export the data to Excel.
Your help is appreciated.
Thanks, Julia

답변 (1개)

Azzi Abdelmalek
Azzi Abdelmalek 2013년 7월 10일
A=[[out1; qc1] teststat pval]
  댓글 수: 1
Julia
Julia 2013년 7월 10일
Thanks, but unfortunately it gives me now this error:??? Error using ==> horzcat CAT arguments dimensions are not consistent.
Error in ==> ReadData at 37 A = [[out1; qc1] teststat pval];
If I change the parentheses to A = {[out1; qc1] teststat pval}. It does again only displays teststat and pval in Excel.
:(

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Tables에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by