Skip to content

Commit

Permalink
bootlm: added relative likelihoods of models to PRED_ERR
Browse files Browse the repository at this point in the history
  • Loading branch information
acp29 committed Jun 10, 2024
1 parent c17e303 commit 2fbc2b3
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: statistics-resampling
version: 5.5.18
date: 2024-06-04
version: 5.5.19
date: 2024-06-10
author: Andrew Penn <[email protected]>
maintainer: Andrew Penn <[email protected]>
title: A statistics package with a variety of resampling tools
Expand Down
8 changes: 6 additions & 2 deletions inst/bootlm.m
Original file line number Diff line number Diff line change
Expand Up @@ -464,6 +464,7 @@
% - 'PE': Bootstrap estimate of prediction error
% - 'PRESS': Bootstrap estimate of predicted residual error sum of squares
% - 'RSQ_pred': Bootstrap estimate of predicted R-squared
% - 'RL': Relative likelihood compared to the intercept-only model
%
% The linear models evaluated are the same as for AOVSTAT, except that the
% output also includes the statistics for the intercept-only model. Note
Expand All @@ -478,7 +479,7 @@
% installed and loaded, then these computations will be automatically
% accelerated by parallel processing on platforms with multiple processors
%
% bootlm (version 2024.05.17)
% bootlm (version 2024.06.10)
% Author: Andrew Charles Penn
% https://www.researchgate.net/profile/Andrew_Penn/
%
Expand Down Expand Up @@ -2131,9 +2132,12 @@
SST = RSS{1}; % Total sum of squares
PE_RSQ = 1 - PRESS / SST; % Predicted R-squared calculated
% by refined bootstrap
RL = exp (-0.5 * (PE - PE(1))); % Relative likelihood (compared
% to the intercept-only model)

% Prepare output
PRED_ERR = struct ('MODEL', [], 'PE', PE, 'PRESS', PRESS, 'RSQ_pred', PE_RSQ);
PRED_ERR = struct ('MODEL', [], 'PE', PE, 'PRESS', PRESS, 'RSQ_pred', ...
PE_RSQ, 'RL', RL);

end

Expand Down
Binary file modified matlab/statistics-resampling.mltbx
Binary file not shown.
4 changes: 2 additions & 2 deletions matlab/statistics-resampling.prj
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<deployment-project plugin="plugin.toolbox" plugin-version="1.0">
<configuration build-checksum="3306453136" file="Y:\Documents\GitHub\statistics-resampling\matlab\statistics-resampling.prj" location="Y:\Documents\GitHub\statistics-resampling\matlab" name="statistics-resampling" target="target.toolbox" target-name="Package Toolbox">
<configuration build-checksum="2568662598" file="Y:\Documents\GitHub\statistics-resampling\matlab\statistics-resampling.prj" location="Y:\Documents\GitHub\statistics-resampling\matlab" name="statistics-resampling" target="target.toolbox" target-name="Package Toolbox">
<param.appname>statistics-resampling</param.appname>
<param.authnamewatermark>Andrew Penn</param.authnamewatermark>
<param.email>[email protected]</param.email>
<param.company>University of Sussex, UK</param.company>
<param.summary>Statistical analysis using resampling methods</param.summary>
<param.description>The statistics-resampling package is an Octave package and Matlab toolbox that can be used to perform a wide variety of statistics tasks using non-parametric resampling methods. In particular, the functions included can be used to estimate bias, uncertainty (standard errors and confidence intervals), prediction error, and calculate p-values for null hypothesis significance tests. Variations of the resampling methods are included that improve the accuracy of the statistics for small samples and samples with complex dependence structures.</param.description>
<param.screenshot>Y:\Documents\GitHub\statistics-resampling\doc\icon.png</param.screenshot>
<param.version>5.5.18</param.version>
<param.version>5.5.19</param.version>
<param.output>${PROJECT_ROOT}\statistics-resampling.mltbx</param.output>
<param.products.name />
<param.products.id />
Expand Down

0 comments on commit 2fbc2b3

Please sign in to comment.