Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi stat one sample #1358

Merged
merged 17 commits into from
Nov 4, 2018
Merged
Show file tree
Hide file tree
Changes from 16 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@
- *DEC*
- Adding missing headers in some files of DEC.
(Roland Denis, [#1349](https://github.com/DGtal-team/DGtal/pull/1349))

- *Math*
- Fix possible division by zero in the MultiStatistics class.
copyme marked this conversation as resolved.
Show resolved Hide resolved

# DGtal 0.9.4.1

Expand Down
7 changes: 5 additions & 2 deletions src/DGtal/math/MultiStatistics.ih
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,11 @@ DGtal::MultiStatistics::terminate()
myExp[ k ] /= mySamples[ k ];
myExp2[ k ] /= mySamples[ k ];
myVar[ k ] = myExp2[ k ] - myExp[ k ] * myExp[ k ];
myUnbiasedVar[ k ] = mySamples[ k ] * myVar[ k ]
/ ( mySamples[ k ] - 1 );
if ( mySamples[ k ] > 1 )
myUnbiasedVar[ k ] = mySamples[ k ] * myVar[ k ] / ( mySamples[ k ] - 1 );
else
myUnbiasedVar[ k ] = 0;

}
myIsTerminate = true;
}
Expand Down
2 changes: 1 addition & 1 deletion src/DGtal/topology/doc/moduleCubicalComplex.dox
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ href="https://gforge.liris.cnrs.fr/projects/imagene">ImaGene</a>.


The following programs are related to this documentation:
cubical-complex-collapse.cpp, cubical-complex-illustrations.cpp,
cubical-complex-collapse.cpp, cubical-complex-illustrations.cpp,
testCubicalComplex.cpp, cubicalComplexThinning.cpp.

@section dgtal_ccomplex_sec1 Introduction to cubical complexes
Expand Down