Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
alta
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
5
Issues
5
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
alta
alta
Commits
3d2306a7
Commit
3d2306a7
authored
Apr 17, 2013
by
Laurent Belcour
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding the choice of the clustrerization.
parent
c0709c9e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
2 deletions
+25
-2
sources/core/data.h
sources/core/data.h
+25
-2
No files found.
sources/core/data.h
View file @
3d2306a7
...
...
@@ -59,13 +59,35 @@ Q_DECLARE_INTERFACE(data, "Fitter.Data")
*/
class
data_params
:
public
data
{
public:
public:
// structures
//! \brief when changing from a parametrization to another, you might
//! lose some dimensions. This list enumerate the different operators
//! that can be applied on the raw data to be clusterized.
//! \note by default we use <em>none</em>, but if the input space
//! dimension is reduced, the program will halt.
enum
clustrering
{
mean
,
median
,
none
};
public:
// methods
//! \brief contructor requires the definition of a base class that
//! has a parametrization, and a new parametrization.
data_params
(
const
data
*
d
,
params
::
type
param
)
:
_d
(
d
),
_param
(
param
)
data_params
(
const
data
*
d
,
params
::
type
param
,
data_params
::
clustrering
method
=
data_params
::
none
)
:
_d
(
d
),
_param
(
param
),
_clustering_method
(
method
)
{
_nX
=
params
::
dimension
(
param
);
_nY
=
d
->
dimY
();
if
(
_nX
<
_d
->
dimX
()
&&
method
==
data_params
::
none
)
{
throw
(
"No cluster method provided"
);
}
}
// Load data from a file
...
...
@@ -117,4 +139,5 @@ protected:
// data object to interface
const
data
*
_d
;
params
::
type
_param
;
data_params
::
clustrering
_clustering_method
;
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment