PALM icon indicating copy to clipboard operation
PALM copied to clipboard

Octave's statistics is not loaded for f-tests

Open jorgman1 opened this issue 3 years ago • 1 comments

I encountered a small problem when running PALM on Debian 10.9 (Octave 4.4.1). When it came to the f-contrasts, the "betainv" function from the statistics package was not loaded and it yielded the following error:

Building null distribution. 80% [Design 1/1, Contrast 9/10, Shuffling 1/5000, Modality 1/1] Saving file: palm_vox_fstat_c9 warning: implicit conversion from numeric to char

Error using palm_gtoz (/opt/PALM/palm_gtoz.m:92) 'betainv' undefined near line 92 column 19

Error in palm_core (/opt/PALM/palm_core.m:1626->palm_gtoz) Error in palm (/opt/PALM/palm.m:81->palm_core)

I solved it by always forcing the package load in palm_takeargs.m (line 1744). I guess there is an "opts.fstat" or similar, that can be added to the if-clause, but I could not find the correct name.

if palm_isoctave
    pkg load statistics
    if opts.spatial.do && any(plm.Yisvol)
        pkg load image
    end
    if opts.accel.lowrank || opts.zstat || opts.corrcon
        pkg load statistics
    end
end

jorgman1 avatar Jun 14 '21 13:06 jorgman1

Hi jorgman1,

Thanks for indicating this. It's a change that can be made for the next version, absolutely. Thanks!

All the best,

Anderson

andersonwinkler avatar Jun 15 '21 13:06 andersonwinkler