File: ndims.m

package info (click to toggle)
octave-dataframe 1.2.0-6
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 784 kB
  • sloc: makefile: 126
file content (12 lines) | stat: -rw-r--r-- 265 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
function resu = ndims(df)
  %# -*- texinfo -*-
  %# @deftypefn {Function File} ndims(@var{df})
  %# overloaded function implementing ndims for a dataframe
  %# @end deftypefn

  resu = 2;
  nseq = max(cellfun(@length, df.x_rep));

  if nseq > 1, resu = 3; end

end