Extracting data from structures to create a table and export to latex
    1 回表示 (過去 30 日間)
  
       古いコメントを表示
    
Dear all, I have a structure object wich is exemplary called mean.usa.gdp, the second level (.usa) has 24 entries, the third level (.gdp) has 3 entries.
which I created in a loop:
if true
Var = {'CGV','GDPV','REGIME'};
nv  = length(Var);
Countries =  {'usa','jap','ger',...,'slo'};   
nc  = length(Countries);
  for ii=1:nc
for jj=1:nv
    eval(['lengths.' Countries{ii} '.' Var{jj} '= length(find(isnan(countrydata.' Countries{ii} '.' Var{jj} ')==0))']);
end
end
end
Now I would like to create a table with the list of countries on the horizontal and the variables on the vertical,
Something like:
       usa | jap | ger | ...
GDPV   ... | ... | ... | ...
CGV    ... | ... | ... | ...
REGIME ... | ... | ... | ...
and I would like to export this table to Latex directly. Any help here would be greatly appreciated!
Best, Philipp
2 件のコメント
  Sasha Egan
 2018 年 11 月 22 日
				I've been waiting over four years for an answer to this question. I asked it my freshman year in college and I have since graduated. Does anyone know how to export tables from matlab to latex without resorting to dlmwrite or writetable with a delimiter and then replace the delimeter with &'s, is there any way to specifiy a custom delimeter?
回答 (0 件)
参考
カテゴリ
				Help Center および File Exchange で LaTeX についてさらに検索
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!