IMP  2.4.0
The Integrative Modeling Platform
WeightedFitParameters.h
Go to the documentation of this file.
1 /**
2  * \file IMP/saxs/WeightedFitParameters.h \brief
3  *
4  * Copyright 2007-2015 IMP Inventors. All rights reserved.
5  *
6  */
7 
8 #ifndef IMPSAXS_WEIGHTED_FIT_PARAMETERS_H
9 #define IMPSAXS_WEIGHTED_FIT_PARAMETERS_H
10 
11 #include <IMP/saxs/saxs_config.h>
12 
13 #include "FitParameters.h"
14 
15 #include <IMP/base_types.h>
16 
17 #include <iostream>
18 
19 IMPSAXS_BEGIN_NAMESPACE
20 
21 class IMPSAXSEXPORT WeightedFitParameters : public FitParameters {
22  public:
23  WeightedFitParameters(float chi, float c1, float c2, Floats weights)
24  : FitParameters(chi, c1, c2), weights_(weights) {}
25 
26  const Floats& get_weights() const { return weights_; }
27 
28  void set_weights(const Floats& weights) { weights_ = weights; }
29 
30  void show(std::ostream& s) const {
31  s << "Chi = " << chi_ << " c1 = " << c1_ << " c2 = " << c2_
32  << " default chi = " << default_chi_ << std::endl;
33  }
34 
35  private:
36  Floats weights_;
37 };
38 
39 IMPSAXS_END_NAMESPACE
40 
41 #endif /* IMPSAXS_WEIGHTED_FIT_PARAMETERS_H */
Import IMP/kernel/base_types.h in the namespace.
Copyright 2007-2015 IMP Inventors. All rights reserved.
void show(Hierarchy h, std::ostream &out=std::cout)
Print out a molecular hierarchy.
IMP::base::Vector< Float > Floats
Standard way to pass a bunch of Float values.
Definition: types.h:47