Skip to content

Commit 8dc67d9

Browse files
committed
Export Chain::get_nb_state()
1 parent 7067a68 commit 8dc67d9

4 files changed

Lines changed: 19 additions & 4 deletions

File tree

conda/meta.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ build:
2525
preserve_egg_dir: True
2626

2727
script:
28-
- {{ PYTHON }} -m pip install . --no-deps --ignore-installed --no-build-isolation -vv
28+
- {{ PYTHON }} -m pip install . --no-deps --ignore-installed --no-build-isolation -vv
2929

3030
requirements:
3131
host:

src/cpp/stat_tool/chain.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -909,6 +909,19 @@ void Chain::log_computation()
909909
}
910910
}
911911

912+
/*--------------------------------------------------------------*/
913+
/**
914+
* \brief Return number of states.
915+
*/
916+
/*--------------------------------------------------------------*/
917+
918+
int Chain::get_nb_state() const
919+
920+
{
921+
return nb_state;
922+
}
923+
924+
912925

913926
/*--------------------------------------------------------------*/
914927
/**

src/cpp/stat_tool/markovian.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,8 @@ namespace stat_tool {
189189

190190
double likelihood_computation(const ChainData &chain_data , bool initial_flag = true) const;
191191
void chi2_fit(const ChainData &chain_data , Test &test) const;
192+
193+
int get_nb_state() const; /// Return number of states
192194
};
193195

194196

test/tools.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
import openalea.stat_tool as st
2222
from openalea.stat_tool import get_shared_data
23-
from openalea.stat_tool.distribution import set_seed
23+
2424

2525

2626
def runTestClass(myclass):
@@ -46,9 +46,9 @@ class interface:
4646
:param structure: reference to a data structure Class that is not instantiated.
4747
4848
:Usage:
49-
In you test file, add::
49+
In your test file, add::
5050
51-
>>> from tools import interface
51+
>>> from .tools import interface
5252
5353
Then, if we consider the Compound class case, create a class as follows::
5454

0 commit comments

Comments
 (0)