alglib 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,7 @@
1
+ === 1.0.1 / 2009-08-20
2
+ * Logit class. Implemented Logit#process and Logit#unpack.
3
+ * Correlation. Implemented Alglib.pearson_correlation and Alglib.spearman_correlation
4
+
1
5
  === 1.0.0 / 2009-07-28
2
6
 
3
7
  * First version of Alglib. Only Multiple Regression Implemented
@@ -238,6 +238,16 @@ ext/alglib/variancetests.cpp
238
238
  ext/alglib/variancetests.h
239
239
  ext/alglib/wsr.cpp
240
240
  ext/alglib/wsr.h
241
+ ext/ap.i
242
+ ext/correlation.i
241
243
  ext/extconf.rb
244
+ ext/logit.i
242
245
  lib/alglib.rb
246
+ lib/alglib/correlation.rb
247
+ lib/alglib/linearregression.rb
248
+ lib/alglib/logit.rb
243
249
  test/test_alglib.rb
250
+ test/test_correlation.rb
251
+ test/test_correlationtest.rb
252
+ test/test_linreg.rb
253
+ test/test_logit.rb
data/README.txt CHANGED
@@ -9,7 +9,7 @@ ALGLIB - is a multilingual collection of algorithms designed to solve problems i
9
9
 
10
10
  == FEATURES/PROBLEMS:
11
11
 
12
- * Only Multiple regression Implemented
12
+ * Only Multiple regression, Logit Regression and Correlation implemented
13
13
 
14
14
 
15
15
  == SYNOPSIS:
data/Rakefile CHANGED
@@ -1,3 +1,4 @@
1
+ #!/usr/bin/ruby
1
2
  # -*- ruby -*-
2
3
 
3
4
  require 'rubygems'
@@ -10,7 +11,7 @@ file "ext/Makefile" => "ext/extconf.rb" do |t|
10
11
  system %(cd ext && ruby extconf.rb)
11
12
  end
12
13
 
13
- file "ext/alglib_ext.so" => ["ext/Makefile","ext/alglib.i"] do |t|
14
+ file "ext/alglib_ext.so" => Dir.glob("ext/*.i")+["ext/Makefile", "ext/alglib/alglib_util.cpp", "ext/alglib/alglib_util.h"] do |t|
14
15
  system %(cd ext && rake)
15
16
 
16
17
  end
@@ -7,12 +7,14 @@ task :test => ["test.rb"] do |t|
7
7
  system %(ruby test.rb)
8
8
  end
9
9
  task :compile => ["alglib.so"]
10
- file "alglib/alglib.cpp"=>["alglib.i"] do |t|
11
- puts "Reconstruyendo swig"
10
+
11
+ file "alglib/alglib.cpp"=>Dir.glob("*.i") do |t|
12
+ puts "Reconstruyendo swig"
12
13
  system %(swig -fvirtual -Wall -c++ -o alglib/alglib.cpp -ruby alglib.i)
13
14
  end
14
- cpp=Dir.glob("alglib/*.cpp")+Dir.glob("alglib/*.h")
15
15
 
16
+
17
+ cpp=Dir.glob("alglib/*.cpp")+Dir.glob("alglib/*.h")
16
18
  file "alglib.so"=>cpp + ["Makefile"] do |t|
17
19
  system %(make)
18
20
  end
@@ -1,160 +1,23 @@
1
1
  %module alglib_ext
2
2
  %{
3
3
  #include "ap.h"
4
- #include "linreg.h"
5
4
  #include "alglib_util.h"
6
5
  #include "iostream"
6
+
7
7
  %}
8
8
 
9
9
  %include "typemaps.i"
10
10
  %apply int *OUTPUT {int& info};
11
11
  %apply int *INPUT {int& nvars};
12
+ %apply int *INPUT {int& nvars};
13
+ %apply int *INPUT {int& nclasses};
14
+ %apply double *INPUT {double &bothtails};
15
+ %apply double *INPUT {double &lefttail};
16
+ %apply double *INPUT {double &righttail};
12
17
 
13
- %typemap(in) ap::real_1d_array {
14
- $1 = new ap::real_1d_array();
15
- $1->setlength(RARRAY_LEN($input));
16
- for(long i=0;i<RARRAY_LEN($input);i++) {
17
- $1->operator()(i)=rb_num2dbl(RARRAY_PTR($input)[i]);
18
- }
19
- }
20
-
21
-
22
- %apply ap::real_1d_array {ap::real_1d_array const &};
23
-
24
- namespace ap {
25
- /********************************************************************
26
- Template of a dynamical one-dimensional array
27
- ********************************************************************/
28
- template<class T, bool Aligned = false>
29
- class template_1d_array
30
- {
31
- public:
32
- template_1d_array();
33
- ~template_1d_array();
34
- template_1d_array(const template_1d_array &rhs);
35
- %extend {
36
- T __getitem__(int i) {
37
- return $self->operator()(i);
38
- };
39
- T __setitem__(int i, T v) {
40
- return $self->operator()(i)=v;
41
- };
42
- int size() {
43
- return $self->gethighbound()-$self->getlowbound();
44
- }
45
- }
46
-
47
- void setbounds( int iLow, int iHigh );
48
- void setlength(int iLen);
49
- void setcontent( int iLow, int iHigh, const T *pContent );
50
- T* getcontent();
51
- int getlowbound(int iBoundNum = 0);
52
- int gethighbound(int iBoundNum = 0);
53
- };
54
-
55
- template<class T, bool Aligned = false>
56
- class template_2d_array
57
- {
58
- public:
59
- template_2d_array();
60
-
61
- ~template_2d_array();
62
-
63
- template_2d_array(const template_2d_array &rhs);
64
- T& operator()(int i1, int i2);
65
-
66
- void setbounds( int iLow1, int iHigh1, int iLow2, int iHigh2 );
67
-
68
- void setlength(int iLen1, int iLen2);
69
-
70
- void setcontent( int iLow1, int iHigh1, int iLow2, int iHigh2, const T *pContent );
71
-
72
- int getlowbound(int iBoundNum) const;
73
-
74
- int gethighbound(int iBoundNum) const;
75
-
76
- %extend {
77
- double __getitem__(int x,int y) {
78
- return $self->operator()(x,y);
79
- }
80
- void __setitem__(int x,int y, T val) {
81
- $self->operator()(x,y)=val;
82
- }
83
-
84
- }
85
-
86
- };
87
-
88
-
89
-
90
- typedef template_1d_array<int> integer_1d_array;
91
- typedef template_1d_array<double,true> real_1d_array;
92
- typedef template_1d_array<complex> complex_1d_array;
93
- typedef template_1d_array<bool> boolean_1d_array;
94
-
95
- typedef template_2d_array<int> integer_2d_array;
96
- typedef template_2d_array<double,true> real_2d_array;
97
- typedef template_2d_array<complex> complex_2d_array;
98
- typedef template_2d_array<bool> boolean_2d_array;
99
-
100
- %template(Integer1dArray) template_1d_array<int>;
101
- %template(Real1dArray) template_1d_array<double,true>;
102
- %template(Boolean1dArray) template_1d_array<bool>;
103
- %template(Integer2dArray) template_2d_array<int>;
104
- %template(Real2dArray) template_2d_array<double,true>;
105
- };
106
-
107
- %rename (LinearModel) linearmodel;
108
- %rename (LrReport) lrreport;
109
-
110
- struct linearmodel
111
- {
112
- ap::real_1d_array w;
113
- };
114
- struct lrreport
115
- {
116
- ap::real_2d_array c;
117
- double rmserror;
118
- double avgerror;
119
- double avgrelerror;
120
- double cvrmserror;
121
- double cvavgerror;
122
- double cvavgrelerror;
123
- int ncvdefects;
124
- ap::integer_1d_array cvdefects;
125
- };
126
-
127
-
128
- void lrbuild(const ap::real_2d_array& xy,
129
- int npoints,
130
- int nvars,
131
- int& info,
132
- linearmodel& lm,
133
- lrreport& ar);
134
18
 
135
- void lrbuilds(const ap::real_2d_array& xy,
136
- const ap::real_1d_array& s,
137
- int npoints,
138
- int nvars,
139
- int& info,
140
- linearmodel& lm,
141
- lrreport& ar);
142
-
143
- void lrbuildzs(const ap::real_2d_array& xy,
144
- const ap::real_1d_array& s,
145
- int npoints,
146
- int nvars,
147
- int& info,
148
- linearmodel& lm,
149
- lrreport& ar);
150
- void lrbuildz(const ap::real_2d_array& xy,
151
- int npoints,
152
- int nvars,
153
- int& info,
154
- linearmodel& lm,
155
- lrreport& ar);
156
-
157
- void lrunpack(const linearmodel& lm, ap::real_1d_array& v, int& nvars);
158
- void lrpack(const ap::real_1d_array& v, int nvars, linearmodel& lm);
159
- double lrprocess(const linearmodel& lm, const ap::real_1d_array& x);
160
- VALUE real1d_to_array(ap::real_1d_array *x);
19
+ %include "ap.i"
20
+ %include "correlation.i"
21
+ %include "correlationtests.i"
22
+ %include "linreg.i"
23
+ %include "logit.i"
@@ -1784,9 +1784,12 @@ int SWIG_Ruby_arity( VALUE proc, int minimal )
1784
1784
  #define SWIGTYPE_p_double swig_types[10]
1785
1785
  #define SWIGTYPE_p_int swig_types[11]
1786
1786
  #define SWIGTYPE_p_linearmodel swig_types[12]
1787
- #define SWIGTYPE_p_lrreport swig_types[13]
1788
- static swig_type_info *swig_types[15];
1789
- static swig_module_info swig_module = {swig_types, 14, 0, 0, 0, 0};
1787
+ #define SWIGTYPE_p_logitmcstate swig_types[13]
1788
+ #define SWIGTYPE_p_logitmodel swig_types[14]
1789
+ #define SWIGTYPE_p_lrreport swig_types[15]
1790
+ #define SWIGTYPE_p_mnlreport swig_types[16]
1791
+ static swig_type_info *swig_types[18];
1792
+ static swig_module_info swig_module = {swig_types, 17, 0, 0, 0, 0};
1790
1793
  #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
1791
1794
  #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
1792
1795
 
@@ -1813,11 +1816,11 @@ static VALUE mAlglib_ext;
1813
1816
 
1814
1817
 
1815
1818
  #include "ap.h"
1816
- #include "linreg.h"
1817
1819
  #include "alglib_util.h"
1818
1820
  #include "iostream"
1819
1821
 
1820
1822
 
1823
+
1821
1824
  #ifdef __cplusplus
1822
1825
  extern "C" {
1823
1826
  #endif
@@ -1913,11 +1916,11 @@ SWIG_From_int (int value)
1913
1916
  return SWIG_From_long (value);
1914
1917
  }
1915
1918
 
1916
- SWIGINTERN int ap_template_1d_array_Sl_int_Sg____setitem__(ap::template_1d_array< int > *self,int i,int v){
1919
+ SWIGINTERN int ap_template_1d_array_Sl_int_Sg____setitem__(ap::template_1d_array< int > *self,int i,int v){
1917
1920
  return self->operator()(i)=v;
1918
1921
  }
1919
- SWIGINTERN int ap_template_1d_array_Sl_int_Sg__size(ap::template_1d_array< int > *self){
1920
- return self->gethighbound()-self->getlowbound();
1922
+ SWIGINTERN int ap_template_1d_array_Sl_int_Sg__size(ap::template_1d_array< int > *self){
1923
+ return self->gethighbound()-self->getlowbound()+1;
1921
1924
  }
1922
1925
  SWIGINTERN double ap_template_1d_array_Sl_double_Sc_true_Sg____getitem__(ap::template_1d_array< double,true > *self,int i){
1923
1926
  return self->operator()(i);
@@ -1954,11 +1957,11 @@ SWIG_AsVal_double (VALUE obj, double *val)
1954
1957
  return SWIG_TypeError;
1955
1958
  }
1956
1959
 
1957
- SWIGINTERN double ap_template_1d_array_Sl_double_Sc_true_Sg____setitem__(ap::template_1d_array< double,true > *self,int i,double v){
1960
+ SWIGINTERN double ap_template_1d_array_Sl_double_Sc_true_Sg____setitem__(ap::template_1d_array< double,true > *self,int i,double v){
1958
1961
  return self->operator()(i)=v;
1959
1962
  }
1960
- SWIGINTERN int ap_template_1d_array_Sl_double_Sc_true_Sg__size(ap::template_1d_array< double,true > *self){
1961
- return self->gethighbound()-self->getlowbound();
1963
+ SWIGINTERN int ap_template_1d_array_Sl_double_Sc_true_Sg__size(ap::template_1d_array< double,true > *self){
1964
+ return self->gethighbound()-self->getlowbound()+1;
1962
1965
  }
1963
1966
  SWIGINTERN bool ap_template_1d_array_Sl_bool_Sg____getitem__(ap::template_1d_array< bool > *self,int i){
1964
1967
  return self->operator()(i);
@@ -1990,11 +1993,11 @@ SWIG_AsVal_bool (VALUE obj, bool *val)
1990
1993
  return SWIG_TypeError;
1991
1994
  }
1992
1995
 
1993
- SWIGINTERN bool ap_template_1d_array_Sl_bool_Sg____setitem__(ap::template_1d_array< bool > *self,int i,bool v){
1996
+ SWIGINTERN bool ap_template_1d_array_Sl_bool_Sg____setitem__(ap::template_1d_array< bool > *self,int i,bool v){
1994
1997
  return self->operator()(i)=v;
1995
1998
  }
1996
- SWIGINTERN int ap_template_1d_array_Sl_bool_Sg__size(ap::template_1d_array< bool > *self){
1997
- return self->gethighbound()-self->getlowbound();
1999
+ SWIGINTERN int ap_template_1d_array_Sl_bool_Sg__size(ap::template_1d_array< bool > *self){
2000
+ return self->gethighbound()-self->getlowbound()+1;
1998
2001
  }
1999
2002
  SWIGINTERN double ap_template_2d_array_Sl_int_Sg____getitem__(ap::template_2d_array< int > *self,int x,int y){
2000
2003
  return self->operator()(x,y);
@@ -2008,6 +2011,66 @@ SWIGINTERN double ap_template_2d_array_Sl_double_Sc_true_Sg____getitem__(ap::tem
2008
2011
  SWIGINTERN void ap_template_2d_array_Sl_double_Sc_true_Sg____setitem__(ap::template_2d_array< double,true > *self,int x,int y,double val){
2009
2012
  self->operator()(x,y)=val;
2010
2013
  }
2014
+
2015
+ #include "correlation.h"
2016
+ #include "ialglib.h"
2017
+
2018
+
2019
+ double wrap_spearmanrankcorrelation(const ap::real_1d_array& x,
2020
+ const ap::real_1d_array& y,
2021
+ int n) {
2022
+ ap::real_1d_array x1,y1;
2023
+ x1=x;
2024
+ y1=y;
2025
+ return spearmanrankcorrelation(x1,y1,n);
2026
+
2027
+ }
2028
+
2029
+
2030
+ #include "correlationtests.h"
2031
+
2032
+
2033
+ VALUE pearsoncorrelationsignificance(double r,
2034
+ int n) {
2035
+ VALUE ary;
2036
+ double bt,lt,rt;
2037
+ pearsoncorrelationsignificance(r, n, bt, lt, rt);
2038
+ ary=rb_ary_new();
2039
+ rb_ary_push(ary, rb_float_new(bt));
2040
+ rb_ary_push(ary, rb_float_new(lt));
2041
+ rb_ary_push(ary, rb_float_new(rt));
2042
+ return ary;
2043
+ }
2044
+
2045
+
2046
+ VALUE spearmanrankcorrelationsignificance(double r,
2047
+ int n) {
2048
+ VALUE ary;
2049
+ double bt,lt,rt;
2050
+ spearmanrankcorrelationsignificance(r, n, bt, lt, rt);
2051
+ ary=rb_ary_new();
2052
+ rb_ary_push(ary, rb_float_new(bt));
2053
+ rb_ary_push(ary, rb_float_new(lt));
2054
+ rb_ary_push(ary, rb_float_new(rt));
2055
+ return ary;
2056
+ }
2057
+
2058
+
2059
+ #include "linreg.h"
2060
+
2061
+
2062
+ #include "logit.h"
2063
+
2064
+
2065
+ VALUE wrap_mnlprocess(logitmodel& lm,
2066
+ const ap::real_1d_array& x) {
2067
+ ap::real_1d_array y;
2068
+ // y.setlength(lm.w(3));
2069
+ mnlprocess(lm,x,y);
2070
+ // std::cout << "Saliendo";
2071
+ return real1d_to_array(&y);
2072
+ }
2073
+
2011
2074
  swig_class cInteger1dArray;
2012
2075
 
2013
2076
  SWIGINTERN VALUE
@@ -4595,6 +4658,197 @@ fail:
4595
4658
  }
4596
4659
 
4597
4660
 
4661
+ SWIGINTERN VALUE
4662
+ _wrap_real1d_to_array(int argc, VALUE *argv, VALUE self) {
4663
+ ap::real_1d_array *arg1 = (ap::real_1d_array *) 0 ;
4664
+ VALUE result;
4665
+ void *argp1 = 0 ;
4666
+ int res1 = 0 ;
4667
+ VALUE vresult = Qnil;
4668
+
4669
+ if ((argc < 1) || (argc > 1)) {
4670
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
4671
+ }
4672
+ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 | 0 );
4673
+ if (!SWIG_IsOK(res1)) {
4674
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "ap::real_1d_array *","real1d_to_array", 1, argv[0] ));
4675
+ }
4676
+ arg1 = reinterpret_cast< ap::real_1d_array * >(argp1);
4677
+ result = (VALUE)real1d_to_array(arg1);
4678
+ vresult = result;
4679
+ return vresult;
4680
+ fail:
4681
+ return Qnil;
4682
+ }
4683
+
4684
+
4685
+ SWIGINTERN VALUE
4686
+ _wrap_array_to_real1d(int argc, VALUE *argv, VALUE self) {
4687
+ VALUE arg1 = (VALUE) 0 ;
4688
+ ap::real_1d_array *arg2 = (ap::real_1d_array *) 0 ;
4689
+ void *argp2 = 0 ;
4690
+ int res2 = 0 ;
4691
+
4692
+ if ((argc < 2) || (argc > 2)) {
4693
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
4694
+ }
4695
+ arg1 = argv[0];
4696
+ res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 | 0 );
4697
+ if (!SWIG_IsOK(res2)) {
4698
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "ap::real_1d_array *","array_to_real1d", 2, argv[1] ));
4699
+ }
4700
+ arg2 = reinterpret_cast< ap::real_1d_array * >(argp2);
4701
+ array_to_real1d(arg1,arg2);
4702
+ return Qnil;
4703
+ fail:
4704
+ return Qnil;
4705
+ }
4706
+
4707
+
4708
+ SWIGINTERN VALUE
4709
+ _wrap_pearsoncorrelation(int argc, VALUE *argv, VALUE self) {
4710
+ ap::real_1d_array *arg1 = 0 ;
4711
+ ap::real_1d_array *arg2 = 0 ;
4712
+ int arg3 ;
4713
+ double result;
4714
+ int val3 ;
4715
+ int ecode3 = 0 ;
4716
+ VALUE vresult = Qnil;
4717
+
4718
+ if ((argc < 3) || (argc > 3)) {
4719
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
4720
+ }
4721
+ {
4722
+ arg1 = new ap::real_1d_array();
4723
+ arg1->setlength(RARRAY_LEN(argv[0]));
4724
+ for(long i=0;i<RARRAY_LEN(argv[0]);i++) {
4725
+ arg1->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[0])[i]);
4726
+ }
4727
+ }
4728
+ {
4729
+ arg2 = new ap::real_1d_array();
4730
+ arg2->setlength(RARRAY_LEN(argv[1]));
4731
+ for(long i=0;i<RARRAY_LEN(argv[1]);i++) {
4732
+ arg2->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[1])[i]);
4733
+ }
4734
+ }
4735
+ ecode3 = SWIG_AsVal_int(argv[2], &val3);
4736
+ if (!SWIG_IsOK(ecode3)) {
4737
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","pearsoncorrelation", 3, argv[2] ));
4738
+ }
4739
+ arg3 = static_cast< int >(val3);
4740
+ result = (double)pearsoncorrelation((ap::template_1d_array< double,true > const &)*arg1,(ap::template_1d_array< double,true > const &)*arg2,arg3);
4741
+ vresult = SWIG_From_double(static_cast< double >(result));
4742
+ return vresult;
4743
+ fail:
4744
+ return Qnil;
4745
+ }
4746
+
4747
+
4748
+ SWIGINTERN VALUE
4749
+ _wrap_spearmanrankcorrelation(int argc, VALUE *argv, VALUE self) {
4750
+ ap::real_1d_array *arg1 = 0 ;
4751
+ ap::real_1d_array *arg2 = 0 ;
4752
+ int arg3 ;
4753
+ double result;
4754
+ int val3 ;
4755
+ int ecode3 = 0 ;
4756
+ VALUE vresult = Qnil;
4757
+
4758
+ if ((argc < 3) || (argc > 3)) {
4759
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
4760
+ }
4761
+ {
4762
+ arg1 = new ap::real_1d_array();
4763
+ arg1->setlength(RARRAY_LEN(argv[0]));
4764
+ for(long i=0;i<RARRAY_LEN(argv[0]);i++) {
4765
+ arg1->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[0])[i]);
4766
+ }
4767
+ }
4768
+ {
4769
+ arg2 = new ap::real_1d_array();
4770
+ arg2->setlength(RARRAY_LEN(argv[1]));
4771
+ for(long i=0;i<RARRAY_LEN(argv[1]);i++) {
4772
+ arg2->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[1])[i]);
4773
+ }
4774
+ }
4775
+ ecode3 = SWIG_AsVal_int(argv[2], &val3);
4776
+ if (!SWIG_IsOK(ecode3)) {
4777
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","wrap_spearmanrankcorrelation", 3, argv[2] ));
4778
+ }
4779
+ arg3 = static_cast< int >(val3);
4780
+ result = (double)wrap_spearmanrankcorrelation((ap::template_1d_array< double,true > const &)*arg1,(ap::template_1d_array< double,true > const &)*arg2,arg3);
4781
+ vresult = SWIG_From_double(static_cast< double >(result));
4782
+ return vresult;
4783
+ fail:
4784
+ return Qnil;
4785
+ }
4786
+
4787
+
4788
+ SWIGINTERN VALUE
4789
+ _wrap_pearsoncorrelationsignificance(int argc, VALUE *argv, VALUE self) {
4790
+ double arg1 ;
4791
+ int arg2 ;
4792
+ VALUE result;
4793
+ double val1 ;
4794
+ int ecode1 = 0 ;
4795
+ int val2 ;
4796
+ int ecode2 = 0 ;
4797
+ VALUE vresult = Qnil;
4798
+
4799
+ if ((argc < 2) || (argc > 2)) {
4800
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
4801
+ }
4802
+ ecode1 = SWIG_AsVal_double(argv[0], &val1);
4803
+ if (!SWIG_IsOK(ecode1)) {
4804
+ SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "double","pearsoncorrelationsignificance", 1, argv[0] ));
4805
+ }
4806
+ arg1 = static_cast< double >(val1);
4807
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
4808
+ if (!SWIG_IsOK(ecode2)) {
4809
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","pearsoncorrelationsignificance", 2, argv[1] ));
4810
+ }
4811
+ arg2 = static_cast< int >(val2);
4812
+ result = (VALUE)pearsoncorrelationsignificance(arg1,arg2);
4813
+ vresult = result;
4814
+ return vresult;
4815
+ fail:
4816
+ return Qnil;
4817
+ }
4818
+
4819
+
4820
+ SWIGINTERN VALUE
4821
+ _wrap_spearmanrankcorrelationsignificance(int argc, VALUE *argv, VALUE self) {
4822
+ double arg1 ;
4823
+ int arg2 ;
4824
+ VALUE result;
4825
+ double val1 ;
4826
+ int ecode1 = 0 ;
4827
+ int val2 ;
4828
+ int ecode2 = 0 ;
4829
+ VALUE vresult = Qnil;
4830
+
4831
+ if ((argc < 2) || (argc > 2)) {
4832
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
4833
+ }
4834
+ ecode1 = SWIG_AsVal_double(argv[0], &val1);
4835
+ if (!SWIG_IsOK(ecode1)) {
4836
+ SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "double","spearmanrankcorrelationsignificance", 1, argv[0] ));
4837
+ }
4838
+ arg1 = static_cast< double >(val1);
4839
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
4840
+ if (!SWIG_IsOK(ecode2)) {
4841
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","spearmanrankcorrelationsignificance", 2, argv[1] ));
4842
+ }
4843
+ arg2 = static_cast< int >(val2);
4844
+ result = (VALUE)spearmanrankcorrelationsignificance(arg1,arg2);
4845
+ vresult = result;
4846
+ return vresult;
4847
+ fail:
4848
+ return Qnil;
4849
+ }
4850
+
4851
+
4598
4852
  swig_class cLinearModel;
4599
4853
 
4600
4854
  SWIGINTERN VALUE
@@ -5646,55 +5900,2054 @@ fail:
5646
5900
  }
5647
5901
 
5648
5902
 
5903
+ swig_class cLogitModel;
5904
+
5649
5905
  SWIGINTERN VALUE
5650
- _wrap_real1d_to_array(int argc, VALUE *argv, VALUE self) {
5651
- ap::real_1d_array *arg1 = (ap::real_1d_array *) 0 ;
5652
- VALUE result;
5906
+ _wrap_LogitModel_w_set(int argc, VALUE *argv, VALUE self) {
5907
+ logitmodel *arg1 = (logitmodel *) 0 ;
5908
+ ap::real_1d_array *arg2 = (ap::real_1d_array *) 0 ;
5653
5909
  void *argp1 = 0 ;
5654
5910
  int res1 = 0 ;
5655
- VALUE vresult = Qnil;
5911
+ void *argp2 = 0 ;
5912
+ int res2 = 0 ;
5656
5913
 
5657
5914
  if ((argc < 1) || (argc > 1)) {
5658
5915
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
5659
5916
  }
5660
- res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 | 0 );
5917
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmodel, 0 | 0 );
5661
5918
  if (!SWIG_IsOK(res1)) {
5662
- SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "ap::real_1d_array *","real1d_to_array", 1, argv[0] ));
5919
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel *","w", 1, self ));
5663
5920
  }
5664
- arg1 = reinterpret_cast< ap::real_1d_array * >(argp1);
5665
- result = (VALUE)real1d_to_array(arg1);
5666
- vresult = result;
5667
- return vresult;
5921
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
5922
+ res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 | 0 );
5923
+ if (!SWIG_IsOK(res2)) {
5924
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "ap::real_1d_array *","w", 2, argv[0] ));
5925
+ }
5926
+ arg2 = reinterpret_cast< ap::real_1d_array * >(argp2);
5927
+ if (arg1) (arg1)->w = *arg2;
5928
+
5929
+ return Qnil;
5668
5930
  fail:
5669
5931
  return Qnil;
5670
5932
  }
5671
5933
 
5672
5934
 
5935
+ SWIGINTERN VALUE
5936
+ _wrap_LogitModel_w_get(int argc, VALUE *argv, VALUE self) {
5937
+ logitmodel *arg1 = (logitmodel *) 0 ;
5938
+ ap::real_1d_array *result = 0 ;
5939
+ void *argp1 = 0 ;
5940
+ int res1 = 0 ;
5941
+ VALUE vresult = Qnil;
5942
+
5943
+ if ((argc < 0) || (argc > 0)) {
5944
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5945
+ }
5946
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmodel, 0 | 0 );
5947
+ if (!SWIG_IsOK(res1)) {
5948
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel *","w", 1, self ));
5949
+ }
5950
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
5951
+ result = (ap::real_1d_array *)& ((arg1)->w);
5952
+ vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 | 0 );
5953
+ return vresult;
5954
+ fail:
5955
+ return Qnil;
5956
+ }
5673
5957
 
5674
- /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
5675
5958
 
5676
- static swig_type_info _swigt__p_ap__template_1d_arrayT_bool_false_t = {"_p_ap__template_1d_arrayT_bool_false_t", "ap::boolean_1d_array *|ap::template_1d_array< bool > *|ap::template_1d_array< bool,false > *", 0, 0, (void*)0, 0};
5677
- static swig_type_info _swigt__p_ap__template_1d_arrayT_complex_false_t = {"_p_ap__template_1d_arrayT_complex_false_t", "ap::complex_1d_array *|ap::template_1d_array< complex,false > *", 0, 0, (void*)0, 0};
5678
- static swig_type_info _swigt__p_ap__template_1d_arrayT_double_true_t = {"_p_ap__template_1d_arrayT_double_true_t", "ap::real_1d_array *|ap::template_1d_array< double,true > *", 0, 0, (void*)0, 0};
5679
- static swig_type_info _swigt__p_ap__template_1d_arrayT_int_false_t = {"_p_ap__template_1d_arrayT_int_false_t", "ap::integer_1d_array *|ap::template_1d_array< int > *|ap::template_1d_array< int,false > *", 0, 0, (void*)0, 0};
5680
- static swig_type_info _swigt__p_ap__template_2d_arrayT_bool_false_t = {"_p_ap__template_2d_arrayT_bool_false_t", "ap::boolean_2d_array *|ap::template_2d_array< bool,false > *", 0, 0, (void*)0, 0};
5681
- static swig_type_info _swigt__p_ap__template_2d_arrayT_complex_false_t = {"_p_ap__template_2d_arrayT_complex_false_t", "ap::complex_2d_array *|ap::template_2d_array< complex,false > *", 0, 0, (void*)0, 0};
5682
- static swig_type_info _swigt__p_ap__template_2d_arrayT_double_true_t = {"_p_ap__template_2d_arrayT_double_true_t", "ap::real_2d_array *|ap::template_2d_array< double,true > *", 0, 0, (void*)0, 0};
5683
- static swig_type_info _swigt__p_ap__template_2d_arrayT_int_false_t = {"_p_ap__template_2d_arrayT_int_false_t", "ap::integer_2d_array *|ap::template_2d_array< int > *|ap::template_2d_array< int,false > *", 0, 0, (void*)0, 0};
5684
- static swig_type_info _swigt__p_bool = {"_p_bool", "bool *", 0, 0, (void*)0, 0};
5685
- static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
5686
- static swig_type_info _swigt__p_double = {"_p_double", "double *", 0, 0, (void*)0, 0};
5687
- static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, (void*)0, 0};
5688
- static swig_type_info _swigt__p_linearmodel = {"_p_linearmodel", "linearmodel *", 0, 0, (void*)0, 0};
5689
- static swig_type_info _swigt__p_lrreport = {"_p_lrreport", "lrreport *", 0, 0, (void*)0, 0};
5959
+ #ifdef HAVE_RB_DEFINE_ALLOC_FUNC
5960
+ SWIGINTERN VALUE
5961
+ _wrap_LogitModel_allocate(VALUE self) {
5962
+ #else
5963
+ SWIGINTERN VALUE
5964
+ _wrap_LogitModel_allocate(int argc, VALUE *argv, VALUE self) {
5965
+ #endif
5966
+
5967
+
5968
+ VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_logitmodel);
5969
+ #ifndef HAVE_RB_DEFINE_ALLOC_FUNC
5970
+ rb_obj_call_init(vresult, argc, argv);
5971
+ #endif
5972
+ return vresult;
5973
+ }
5974
+
5690
5975
 
5691
- static swig_type_info *swig_type_initial[] = {
5692
- &_swigt__p_ap__template_1d_arrayT_bool_false_t,
5693
- &_swigt__p_ap__template_1d_arrayT_complex_false_t,
5694
- &_swigt__p_ap__template_1d_arrayT_double_true_t,
5695
- &_swigt__p_ap__template_1d_arrayT_int_false_t,
5696
- &_swigt__p_ap__template_2d_arrayT_bool_false_t,
5697
- &_swigt__p_ap__template_2d_arrayT_complex_false_t,
5976
+ SWIGINTERN VALUE
5977
+ _wrap_new_LogitModel(int argc, VALUE *argv, VALUE self) {
5978
+ logitmodel *result = 0 ;
5979
+
5980
+ if ((argc < 0) || (argc > 0)) {
5981
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
5982
+ }
5983
+ result = (logitmodel *)new logitmodel();DATA_PTR(self) = result;
5984
+
5985
+ return self;
5986
+ fail:
5987
+ return Qnil;
5988
+ }
5989
+
5990
+
5991
+ SWIGINTERN void
5992
+ free_logitmodel(logitmodel *arg1) {
5993
+ delete arg1;
5994
+ }
5995
+
5996
+ swig_class cLogitMcState;
5997
+
5998
+ SWIGINTERN VALUE
5999
+ _wrap_LogitMcState_brackt_set(int argc, VALUE *argv, VALUE self) {
6000
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6001
+ bool arg2 ;
6002
+ void *argp1 = 0 ;
6003
+ int res1 = 0 ;
6004
+ bool val2 ;
6005
+ int ecode2 = 0 ;
6006
+
6007
+ if ((argc < 1) || (argc > 1)) {
6008
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6009
+ }
6010
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6011
+ if (!SWIG_IsOK(res1)) {
6012
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","brackt", 1, self ));
6013
+ }
6014
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6015
+ ecode2 = SWIG_AsVal_bool(argv[0], &val2);
6016
+ if (!SWIG_IsOK(ecode2)) {
6017
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "bool","brackt", 2, argv[0] ));
6018
+ }
6019
+ arg2 = static_cast< bool >(val2);
6020
+ if (arg1) (arg1)->brackt = arg2;
6021
+
6022
+ return Qnil;
6023
+ fail:
6024
+ return Qnil;
6025
+ }
6026
+
6027
+
6028
+ SWIGINTERN VALUE
6029
+ _wrap_LogitMcState_brackt_get(int argc, VALUE *argv, VALUE self) {
6030
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6031
+ bool result;
6032
+ void *argp1 = 0 ;
6033
+ int res1 = 0 ;
6034
+ VALUE vresult = Qnil;
6035
+
6036
+ if ((argc < 0) || (argc > 0)) {
6037
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6038
+ }
6039
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6040
+ if (!SWIG_IsOK(res1)) {
6041
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","brackt", 1, self ));
6042
+ }
6043
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6044
+ result = (bool) ((arg1)->brackt);
6045
+ vresult = SWIG_From_bool(static_cast< bool >(result));
6046
+ return vresult;
6047
+ fail:
6048
+ return Qnil;
6049
+ }
6050
+
6051
+
6052
+ SWIGINTERN VALUE
6053
+ _wrap_LogitMcState_stage1_set(int argc, VALUE *argv, VALUE self) {
6054
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6055
+ bool arg2 ;
6056
+ void *argp1 = 0 ;
6057
+ int res1 = 0 ;
6058
+ bool val2 ;
6059
+ int ecode2 = 0 ;
6060
+
6061
+ if ((argc < 1) || (argc > 1)) {
6062
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6063
+ }
6064
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6065
+ if (!SWIG_IsOK(res1)) {
6066
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stage1", 1, self ));
6067
+ }
6068
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6069
+ ecode2 = SWIG_AsVal_bool(argv[0], &val2);
6070
+ if (!SWIG_IsOK(ecode2)) {
6071
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "bool","stage1", 2, argv[0] ));
6072
+ }
6073
+ arg2 = static_cast< bool >(val2);
6074
+ if (arg1) (arg1)->stage1 = arg2;
6075
+
6076
+ return Qnil;
6077
+ fail:
6078
+ return Qnil;
6079
+ }
6080
+
6081
+
6082
+ SWIGINTERN VALUE
6083
+ _wrap_LogitMcState_stage1_get(int argc, VALUE *argv, VALUE self) {
6084
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6085
+ bool result;
6086
+ void *argp1 = 0 ;
6087
+ int res1 = 0 ;
6088
+ VALUE vresult = Qnil;
6089
+
6090
+ if ((argc < 0) || (argc > 0)) {
6091
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6092
+ }
6093
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6094
+ if (!SWIG_IsOK(res1)) {
6095
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stage1", 1, self ));
6096
+ }
6097
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6098
+ result = (bool) ((arg1)->stage1);
6099
+ vresult = SWIG_From_bool(static_cast< bool >(result));
6100
+ return vresult;
6101
+ fail:
6102
+ return Qnil;
6103
+ }
6104
+
6105
+
6106
+ SWIGINTERN VALUE
6107
+ _wrap_LogitMcState_infoc_set(int argc, VALUE *argv, VALUE self) {
6108
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6109
+ int arg2 ;
6110
+ void *argp1 = 0 ;
6111
+ int res1 = 0 ;
6112
+ int val2 ;
6113
+ int ecode2 = 0 ;
6114
+
6115
+ if ((argc < 1) || (argc > 1)) {
6116
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6117
+ }
6118
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6119
+ if (!SWIG_IsOK(res1)) {
6120
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","infoc", 1, self ));
6121
+ }
6122
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6123
+ ecode2 = SWIG_AsVal_int(argv[0], &val2);
6124
+ if (!SWIG_IsOK(ecode2)) {
6125
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","infoc", 2, argv[0] ));
6126
+ }
6127
+ arg2 = static_cast< int >(val2);
6128
+ if (arg1) (arg1)->infoc = arg2;
6129
+
6130
+ return Qnil;
6131
+ fail:
6132
+ return Qnil;
6133
+ }
6134
+
6135
+
6136
+ SWIGINTERN VALUE
6137
+ _wrap_LogitMcState_infoc_get(int argc, VALUE *argv, VALUE self) {
6138
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6139
+ int result;
6140
+ void *argp1 = 0 ;
6141
+ int res1 = 0 ;
6142
+ VALUE vresult = Qnil;
6143
+
6144
+ if ((argc < 0) || (argc > 0)) {
6145
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6146
+ }
6147
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6148
+ if (!SWIG_IsOK(res1)) {
6149
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","infoc", 1, self ));
6150
+ }
6151
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6152
+ result = (int) ((arg1)->infoc);
6153
+ vresult = SWIG_From_int(static_cast< int >(result));
6154
+ return vresult;
6155
+ fail:
6156
+ return Qnil;
6157
+ }
6158
+
6159
+
6160
+ SWIGINTERN VALUE
6161
+ _wrap_LogitMcState_dg_set(int argc, VALUE *argv, VALUE self) {
6162
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6163
+ double arg2 ;
6164
+ void *argp1 = 0 ;
6165
+ int res1 = 0 ;
6166
+ double val2 ;
6167
+ int ecode2 = 0 ;
6168
+
6169
+ if ((argc < 1) || (argc > 1)) {
6170
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6171
+ }
6172
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6173
+ if (!SWIG_IsOK(res1)) {
6174
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dg", 1, self ));
6175
+ }
6176
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6177
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6178
+ if (!SWIG_IsOK(ecode2)) {
6179
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dg", 2, argv[0] ));
6180
+ }
6181
+ arg2 = static_cast< double >(val2);
6182
+ if (arg1) (arg1)->dg = arg2;
6183
+
6184
+ return Qnil;
6185
+ fail:
6186
+ return Qnil;
6187
+ }
6188
+
6189
+
6190
+ SWIGINTERN VALUE
6191
+ _wrap_LogitMcState_dg_get(int argc, VALUE *argv, VALUE self) {
6192
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6193
+ double result;
6194
+ void *argp1 = 0 ;
6195
+ int res1 = 0 ;
6196
+ VALUE vresult = Qnil;
6197
+
6198
+ if ((argc < 0) || (argc > 0)) {
6199
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6200
+ }
6201
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6202
+ if (!SWIG_IsOK(res1)) {
6203
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dg", 1, self ));
6204
+ }
6205
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6206
+ result = (double) ((arg1)->dg);
6207
+ vresult = SWIG_From_double(static_cast< double >(result));
6208
+ return vresult;
6209
+ fail:
6210
+ return Qnil;
6211
+ }
6212
+
6213
+
6214
+ SWIGINTERN VALUE
6215
+ _wrap_LogitMcState_dgm_set(int argc, VALUE *argv, VALUE self) {
6216
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6217
+ double arg2 ;
6218
+ void *argp1 = 0 ;
6219
+ int res1 = 0 ;
6220
+ double val2 ;
6221
+ int ecode2 = 0 ;
6222
+
6223
+ if ((argc < 1) || (argc > 1)) {
6224
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6225
+ }
6226
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6227
+ if (!SWIG_IsOK(res1)) {
6228
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgm", 1, self ));
6229
+ }
6230
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6231
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6232
+ if (!SWIG_IsOK(ecode2)) {
6233
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgm", 2, argv[0] ));
6234
+ }
6235
+ arg2 = static_cast< double >(val2);
6236
+ if (arg1) (arg1)->dgm = arg2;
6237
+
6238
+ return Qnil;
6239
+ fail:
6240
+ return Qnil;
6241
+ }
6242
+
6243
+
6244
+ SWIGINTERN VALUE
6245
+ _wrap_LogitMcState_dgm_get(int argc, VALUE *argv, VALUE self) {
6246
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6247
+ double result;
6248
+ void *argp1 = 0 ;
6249
+ int res1 = 0 ;
6250
+ VALUE vresult = Qnil;
6251
+
6252
+ if ((argc < 0) || (argc > 0)) {
6253
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6254
+ }
6255
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6256
+ if (!SWIG_IsOK(res1)) {
6257
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgm", 1, self ));
6258
+ }
6259
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6260
+ result = (double) ((arg1)->dgm);
6261
+ vresult = SWIG_From_double(static_cast< double >(result));
6262
+ return vresult;
6263
+ fail:
6264
+ return Qnil;
6265
+ }
6266
+
6267
+
6268
+ SWIGINTERN VALUE
6269
+ _wrap_LogitMcState_dginit_set(int argc, VALUE *argv, VALUE self) {
6270
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6271
+ double arg2 ;
6272
+ void *argp1 = 0 ;
6273
+ int res1 = 0 ;
6274
+ double val2 ;
6275
+ int ecode2 = 0 ;
6276
+
6277
+ if ((argc < 1) || (argc > 1)) {
6278
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6279
+ }
6280
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6281
+ if (!SWIG_IsOK(res1)) {
6282
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dginit", 1, self ));
6283
+ }
6284
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6285
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6286
+ if (!SWIG_IsOK(ecode2)) {
6287
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dginit", 2, argv[0] ));
6288
+ }
6289
+ arg2 = static_cast< double >(val2);
6290
+ if (arg1) (arg1)->dginit = arg2;
6291
+
6292
+ return Qnil;
6293
+ fail:
6294
+ return Qnil;
6295
+ }
6296
+
6297
+
6298
+ SWIGINTERN VALUE
6299
+ _wrap_LogitMcState_dginit_get(int argc, VALUE *argv, VALUE self) {
6300
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6301
+ double result;
6302
+ void *argp1 = 0 ;
6303
+ int res1 = 0 ;
6304
+ VALUE vresult = Qnil;
6305
+
6306
+ if ((argc < 0) || (argc > 0)) {
6307
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6308
+ }
6309
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6310
+ if (!SWIG_IsOK(res1)) {
6311
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dginit", 1, self ));
6312
+ }
6313
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6314
+ result = (double) ((arg1)->dginit);
6315
+ vresult = SWIG_From_double(static_cast< double >(result));
6316
+ return vresult;
6317
+ fail:
6318
+ return Qnil;
6319
+ }
6320
+
6321
+
6322
+ SWIGINTERN VALUE
6323
+ _wrap_LogitMcState_dgtest_set(int argc, VALUE *argv, VALUE self) {
6324
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6325
+ double arg2 ;
6326
+ void *argp1 = 0 ;
6327
+ int res1 = 0 ;
6328
+ double val2 ;
6329
+ int ecode2 = 0 ;
6330
+
6331
+ if ((argc < 1) || (argc > 1)) {
6332
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6333
+ }
6334
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6335
+ if (!SWIG_IsOK(res1)) {
6336
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgtest", 1, self ));
6337
+ }
6338
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6339
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6340
+ if (!SWIG_IsOK(ecode2)) {
6341
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgtest", 2, argv[0] ));
6342
+ }
6343
+ arg2 = static_cast< double >(val2);
6344
+ if (arg1) (arg1)->dgtest = arg2;
6345
+
6346
+ return Qnil;
6347
+ fail:
6348
+ return Qnil;
6349
+ }
6350
+
6351
+
6352
+ SWIGINTERN VALUE
6353
+ _wrap_LogitMcState_dgtest_get(int argc, VALUE *argv, VALUE self) {
6354
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6355
+ double result;
6356
+ void *argp1 = 0 ;
6357
+ int res1 = 0 ;
6358
+ VALUE vresult = Qnil;
6359
+
6360
+ if ((argc < 0) || (argc > 0)) {
6361
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6362
+ }
6363
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6364
+ if (!SWIG_IsOK(res1)) {
6365
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgtest", 1, self ));
6366
+ }
6367
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6368
+ result = (double) ((arg1)->dgtest);
6369
+ vresult = SWIG_From_double(static_cast< double >(result));
6370
+ return vresult;
6371
+ fail:
6372
+ return Qnil;
6373
+ }
6374
+
6375
+
6376
+ SWIGINTERN VALUE
6377
+ _wrap_LogitMcState_dgx_set(int argc, VALUE *argv, VALUE self) {
6378
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6379
+ double arg2 ;
6380
+ void *argp1 = 0 ;
6381
+ int res1 = 0 ;
6382
+ double val2 ;
6383
+ int ecode2 = 0 ;
6384
+
6385
+ if ((argc < 1) || (argc > 1)) {
6386
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6387
+ }
6388
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6389
+ if (!SWIG_IsOK(res1)) {
6390
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgx", 1, self ));
6391
+ }
6392
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6393
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6394
+ if (!SWIG_IsOK(ecode2)) {
6395
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgx", 2, argv[0] ));
6396
+ }
6397
+ arg2 = static_cast< double >(val2);
6398
+ if (arg1) (arg1)->dgx = arg2;
6399
+
6400
+ return Qnil;
6401
+ fail:
6402
+ return Qnil;
6403
+ }
6404
+
6405
+
6406
+ SWIGINTERN VALUE
6407
+ _wrap_LogitMcState_dgx_get(int argc, VALUE *argv, VALUE self) {
6408
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6409
+ double result;
6410
+ void *argp1 = 0 ;
6411
+ int res1 = 0 ;
6412
+ VALUE vresult = Qnil;
6413
+
6414
+ if ((argc < 0) || (argc > 0)) {
6415
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6416
+ }
6417
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6418
+ if (!SWIG_IsOK(res1)) {
6419
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgx", 1, self ));
6420
+ }
6421
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6422
+ result = (double) ((arg1)->dgx);
6423
+ vresult = SWIG_From_double(static_cast< double >(result));
6424
+ return vresult;
6425
+ fail:
6426
+ return Qnil;
6427
+ }
6428
+
6429
+
6430
+ SWIGINTERN VALUE
6431
+ _wrap_LogitMcState_dgxm_set(int argc, VALUE *argv, VALUE self) {
6432
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6433
+ double arg2 ;
6434
+ void *argp1 = 0 ;
6435
+ int res1 = 0 ;
6436
+ double val2 ;
6437
+ int ecode2 = 0 ;
6438
+
6439
+ if ((argc < 1) || (argc > 1)) {
6440
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6441
+ }
6442
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6443
+ if (!SWIG_IsOK(res1)) {
6444
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgxm", 1, self ));
6445
+ }
6446
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6447
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6448
+ if (!SWIG_IsOK(ecode2)) {
6449
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgxm", 2, argv[0] ));
6450
+ }
6451
+ arg2 = static_cast< double >(val2);
6452
+ if (arg1) (arg1)->dgxm = arg2;
6453
+
6454
+ return Qnil;
6455
+ fail:
6456
+ return Qnil;
6457
+ }
6458
+
6459
+
6460
+ SWIGINTERN VALUE
6461
+ _wrap_LogitMcState_dgxm_get(int argc, VALUE *argv, VALUE self) {
6462
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6463
+ double result;
6464
+ void *argp1 = 0 ;
6465
+ int res1 = 0 ;
6466
+ VALUE vresult = Qnil;
6467
+
6468
+ if ((argc < 0) || (argc > 0)) {
6469
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6470
+ }
6471
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6472
+ if (!SWIG_IsOK(res1)) {
6473
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgxm", 1, self ));
6474
+ }
6475
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6476
+ result = (double) ((arg1)->dgxm);
6477
+ vresult = SWIG_From_double(static_cast< double >(result));
6478
+ return vresult;
6479
+ fail:
6480
+ return Qnil;
6481
+ }
6482
+
6483
+
6484
+ SWIGINTERN VALUE
6485
+ _wrap_LogitMcState_dgy_set(int argc, VALUE *argv, VALUE self) {
6486
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6487
+ double arg2 ;
6488
+ void *argp1 = 0 ;
6489
+ int res1 = 0 ;
6490
+ double val2 ;
6491
+ int ecode2 = 0 ;
6492
+
6493
+ if ((argc < 1) || (argc > 1)) {
6494
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6495
+ }
6496
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6497
+ if (!SWIG_IsOK(res1)) {
6498
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgy", 1, self ));
6499
+ }
6500
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6501
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6502
+ if (!SWIG_IsOK(ecode2)) {
6503
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgy", 2, argv[0] ));
6504
+ }
6505
+ arg2 = static_cast< double >(val2);
6506
+ if (arg1) (arg1)->dgy = arg2;
6507
+
6508
+ return Qnil;
6509
+ fail:
6510
+ return Qnil;
6511
+ }
6512
+
6513
+
6514
+ SWIGINTERN VALUE
6515
+ _wrap_LogitMcState_dgy_get(int argc, VALUE *argv, VALUE self) {
6516
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6517
+ double result;
6518
+ void *argp1 = 0 ;
6519
+ int res1 = 0 ;
6520
+ VALUE vresult = Qnil;
6521
+
6522
+ if ((argc < 0) || (argc > 0)) {
6523
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6524
+ }
6525
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6526
+ if (!SWIG_IsOK(res1)) {
6527
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgy", 1, self ));
6528
+ }
6529
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6530
+ result = (double) ((arg1)->dgy);
6531
+ vresult = SWIG_From_double(static_cast< double >(result));
6532
+ return vresult;
6533
+ fail:
6534
+ return Qnil;
6535
+ }
6536
+
6537
+
6538
+ SWIGINTERN VALUE
6539
+ _wrap_LogitMcState_dgym_set(int argc, VALUE *argv, VALUE self) {
6540
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6541
+ double arg2 ;
6542
+ void *argp1 = 0 ;
6543
+ int res1 = 0 ;
6544
+ double val2 ;
6545
+ int ecode2 = 0 ;
6546
+
6547
+ if ((argc < 1) || (argc > 1)) {
6548
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6549
+ }
6550
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6551
+ if (!SWIG_IsOK(res1)) {
6552
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgym", 1, self ));
6553
+ }
6554
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6555
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6556
+ if (!SWIG_IsOK(ecode2)) {
6557
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","dgym", 2, argv[0] ));
6558
+ }
6559
+ arg2 = static_cast< double >(val2);
6560
+ if (arg1) (arg1)->dgym = arg2;
6561
+
6562
+ return Qnil;
6563
+ fail:
6564
+ return Qnil;
6565
+ }
6566
+
6567
+
6568
+ SWIGINTERN VALUE
6569
+ _wrap_LogitMcState_dgym_get(int argc, VALUE *argv, VALUE self) {
6570
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6571
+ double result;
6572
+ void *argp1 = 0 ;
6573
+ int res1 = 0 ;
6574
+ VALUE vresult = Qnil;
6575
+
6576
+ if ((argc < 0) || (argc > 0)) {
6577
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6578
+ }
6579
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6580
+ if (!SWIG_IsOK(res1)) {
6581
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","dgym", 1, self ));
6582
+ }
6583
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6584
+ result = (double) ((arg1)->dgym);
6585
+ vresult = SWIG_From_double(static_cast< double >(result));
6586
+ return vresult;
6587
+ fail:
6588
+ return Qnil;
6589
+ }
6590
+
6591
+
6592
+ SWIGINTERN VALUE
6593
+ _wrap_LogitMcState_finit_set(int argc, VALUE *argv, VALUE self) {
6594
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6595
+ double arg2 ;
6596
+ void *argp1 = 0 ;
6597
+ int res1 = 0 ;
6598
+ double val2 ;
6599
+ int ecode2 = 0 ;
6600
+
6601
+ if ((argc < 1) || (argc > 1)) {
6602
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6603
+ }
6604
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6605
+ if (!SWIG_IsOK(res1)) {
6606
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","finit", 1, self ));
6607
+ }
6608
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6609
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6610
+ if (!SWIG_IsOK(ecode2)) {
6611
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","finit", 2, argv[0] ));
6612
+ }
6613
+ arg2 = static_cast< double >(val2);
6614
+ if (arg1) (arg1)->finit = arg2;
6615
+
6616
+ return Qnil;
6617
+ fail:
6618
+ return Qnil;
6619
+ }
6620
+
6621
+
6622
+ SWIGINTERN VALUE
6623
+ _wrap_LogitMcState_finit_get(int argc, VALUE *argv, VALUE self) {
6624
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6625
+ double result;
6626
+ void *argp1 = 0 ;
6627
+ int res1 = 0 ;
6628
+ VALUE vresult = Qnil;
6629
+
6630
+ if ((argc < 0) || (argc > 0)) {
6631
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6632
+ }
6633
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6634
+ if (!SWIG_IsOK(res1)) {
6635
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","finit", 1, self ));
6636
+ }
6637
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6638
+ result = (double) ((arg1)->finit);
6639
+ vresult = SWIG_From_double(static_cast< double >(result));
6640
+ return vresult;
6641
+ fail:
6642
+ return Qnil;
6643
+ }
6644
+
6645
+
6646
+ SWIGINTERN VALUE
6647
+ _wrap_LogitMcState_ftest1_set(int argc, VALUE *argv, VALUE self) {
6648
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6649
+ double arg2 ;
6650
+ void *argp1 = 0 ;
6651
+ int res1 = 0 ;
6652
+ double val2 ;
6653
+ int ecode2 = 0 ;
6654
+
6655
+ if ((argc < 1) || (argc > 1)) {
6656
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6657
+ }
6658
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6659
+ if (!SWIG_IsOK(res1)) {
6660
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","ftest1", 1, self ));
6661
+ }
6662
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6663
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6664
+ if (!SWIG_IsOK(ecode2)) {
6665
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","ftest1", 2, argv[0] ));
6666
+ }
6667
+ arg2 = static_cast< double >(val2);
6668
+ if (arg1) (arg1)->ftest1 = arg2;
6669
+
6670
+ return Qnil;
6671
+ fail:
6672
+ return Qnil;
6673
+ }
6674
+
6675
+
6676
+ SWIGINTERN VALUE
6677
+ _wrap_LogitMcState_ftest1_get(int argc, VALUE *argv, VALUE self) {
6678
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6679
+ double result;
6680
+ void *argp1 = 0 ;
6681
+ int res1 = 0 ;
6682
+ VALUE vresult = Qnil;
6683
+
6684
+ if ((argc < 0) || (argc > 0)) {
6685
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6686
+ }
6687
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6688
+ if (!SWIG_IsOK(res1)) {
6689
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","ftest1", 1, self ));
6690
+ }
6691
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6692
+ result = (double) ((arg1)->ftest1);
6693
+ vresult = SWIG_From_double(static_cast< double >(result));
6694
+ return vresult;
6695
+ fail:
6696
+ return Qnil;
6697
+ }
6698
+
6699
+
6700
+ SWIGINTERN VALUE
6701
+ _wrap_LogitMcState_fm_set(int argc, VALUE *argv, VALUE self) {
6702
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6703
+ double arg2 ;
6704
+ void *argp1 = 0 ;
6705
+ int res1 = 0 ;
6706
+ double val2 ;
6707
+ int ecode2 = 0 ;
6708
+
6709
+ if ((argc < 1) || (argc > 1)) {
6710
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6711
+ }
6712
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6713
+ if (!SWIG_IsOK(res1)) {
6714
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fm", 1, self ));
6715
+ }
6716
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6717
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6718
+ if (!SWIG_IsOK(ecode2)) {
6719
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","fm", 2, argv[0] ));
6720
+ }
6721
+ arg2 = static_cast< double >(val2);
6722
+ if (arg1) (arg1)->fm = arg2;
6723
+
6724
+ return Qnil;
6725
+ fail:
6726
+ return Qnil;
6727
+ }
6728
+
6729
+
6730
+ SWIGINTERN VALUE
6731
+ _wrap_LogitMcState_fm_get(int argc, VALUE *argv, VALUE self) {
6732
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6733
+ double result;
6734
+ void *argp1 = 0 ;
6735
+ int res1 = 0 ;
6736
+ VALUE vresult = Qnil;
6737
+
6738
+ if ((argc < 0) || (argc > 0)) {
6739
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6740
+ }
6741
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6742
+ if (!SWIG_IsOK(res1)) {
6743
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fm", 1, self ));
6744
+ }
6745
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6746
+ result = (double) ((arg1)->fm);
6747
+ vresult = SWIG_From_double(static_cast< double >(result));
6748
+ return vresult;
6749
+ fail:
6750
+ return Qnil;
6751
+ }
6752
+
6753
+
6754
+ SWIGINTERN VALUE
6755
+ _wrap_LogitMcState_fx_set(int argc, VALUE *argv, VALUE self) {
6756
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6757
+ double arg2 ;
6758
+ void *argp1 = 0 ;
6759
+ int res1 = 0 ;
6760
+ double val2 ;
6761
+ int ecode2 = 0 ;
6762
+
6763
+ if ((argc < 1) || (argc > 1)) {
6764
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6765
+ }
6766
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6767
+ if (!SWIG_IsOK(res1)) {
6768
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fx", 1, self ));
6769
+ }
6770
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6771
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6772
+ if (!SWIG_IsOK(ecode2)) {
6773
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","fx", 2, argv[0] ));
6774
+ }
6775
+ arg2 = static_cast< double >(val2);
6776
+ if (arg1) (arg1)->fx = arg2;
6777
+
6778
+ return Qnil;
6779
+ fail:
6780
+ return Qnil;
6781
+ }
6782
+
6783
+
6784
+ SWIGINTERN VALUE
6785
+ _wrap_LogitMcState_fx_get(int argc, VALUE *argv, VALUE self) {
6786
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6787
+ double result;
6788
+ void *argp1 = 0 ;
6789
+ int res1 = 0 ;
6790
+ VALUE vresult = Qnil;
6791
+
6792
+ if ((argc < 0) || (argc > 0)) {
6793
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6794
+ }
6795
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6796
+ if (!SWIG_IsOK(res1)) {
6797
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fx", 1, self ));
6798
+ }
6799
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6800
+ result = (double) ((arg1)->fx);
6801
+ vresult = SWIG_From_double(static_cast< double >(result));
6802
+ return vresult;
6803
+ fail:
6804
+ return Qnil;
6805
+ }
6806
+
6807
+
6808
+ SWIGINTERN VALUE
6809
+ _wrap_LogitMcState_fxm_set(int argc, VALUE *argv, VALUE self) {
6810
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6811
+ double arg2 ;
6812
+ void *argp1 = 0 ;
6813
+ int res1 = 0 ;
6814
+ double val2 ;
6815
+ int ecode2 = 0 ;
6816
+
6817
+ if ((argc < 1) || (argc > 1)) {
6818
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6819
+ }
6820
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6821
+ if (!SWIG_IsOK(res1)) {
6822
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fxm", 1, self ));
6823
+ }
6824
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6825
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6826
+ if (!SWIG_IsOK(ecode2)) {
6827
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","fxm", 2, argv[0] ));
6828
+ }
6829
+ arg2 = static_cast< double >(val2);
6830
+ if (arg1) (arg1)->fxm = arg2;
6831
+
6832
+ return Qnil;
6833
+ fail:
6834
+ return Qnil;
6835
+ }
6836
+
6837
+
6838
+ SWIGINTERN VALUE
6839
+ _wrap_LogitMcState_fxm_get(int argc, VALUE *argv, VALUE self) {
6840
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6841
+ double result;
6842
+ void *argp1 = 0 ;
6843
+ int res1 = 0 ;
6844
+ VALUE vresult = Qnil;
6845
+
6846
+ if ((argc < 0) || (argc > 0)) {
6847
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6848
+ }
6849
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6850
+ if (!SWIG_IsOK(res1)) {
6851
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fxm", 1, self ));
6852
+ }
6853
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6854
+ result = (double) ((arg1)->fxm);
6855
+ vresult = SWIG_From_double(static_cast< double >(result));
6856
+ return vresult;
6857
+ fail:
6858
+ return Qnil;
6859
+ }
6860
+
6861
+
6862
+ SWIGINTERN VALUE
6863
+ _wrap_LogitMcState_fy_set(int argc, VALUE *argv, VALUE self) {
6864
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6865
+ double arg2 ;
6866
+ void *argp1 = 0 ;
6867
+ int res1 = 0 ;
6868
+ double val2 ;
6869
+ int ecode2 = 0 ;
6870
+
6871
+ if ((argc < 1) || (argc > 1)) {
6872
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6873
+ }
6874
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6875
+ if (!SWIG_IsOK(res1)) {
6876
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fy", 1, self ));
6877
+ }
6878
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6879
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6880
+ if (!SWIG_IsOK(ecode2)) {
6881
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","fy", 2, argv[0] ));
6882
+ }
6883
+ arg2 = static_cast< double >(val2);
6884
+ if (arg1) (arg1)->fy = arg2;
6885
+
6886
+ return Qnil;
6887
+ fail:
6888
+ return Qnil;
6889
+ }
6890
+
6891
+
6892
+ SWIGINTERN VALUE
6893
+ _wrap_LogitMcState_fy_get(int argc, VALUE *argv, VALUE self) {
6894
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6895
+ double result;
6896
+ void *argp1 = 0 ;
6897
+ int res1 = 0 ;
6898
+ VALUE vresult = Qnil;
6899
+
6900
+ if ((argc < 0) || (argc > 0)) {
6901
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6902
+ }
6903
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6904
+ if (!SWIG_IsOK(res1)) {
6905
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fy", 1, self ));
6906
+ }
6907
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6908
+ result = (double) ((arg1)->fy);
6909
+ vresult = SWIG_From_double(static_cast< double >(result));
6910
+ return vresult;
6911
+ fail:
6912
+ return Qnil;
6913
+ }
6914
+
6915
+
6916
+ SWIGINTERN VALUE
6917
+ _wrap_LogitMcState_fym_set(int argc, VALUE *argv, VALUE self) {
6918
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6919
+ double arg2 ;
6920
+ void *argp1 = 0 ;
6921
+ int res1 = 0 ;
6922
+ double val2 ;
6923
+ int ecode2 = 0 ;
6924
+
6925
+ if ((argc < 1) || (argc > 1)) {
6926
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6927
+ }
6928
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6929
+ if (!SWIG_IsOK(res1)) {
6930
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fym", 1, self ));
6931
+ }
6932
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6933
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6934
+ if (!SWIG_IsOK(ecode2)) {
6935
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","fym", 2, argv[0] ));
6936
+ }
6937
+ arg2 = static_cast< double >(val2);
6938
+ if (arg1) (arg1)->fym = arg2;
6939
+
6940
+ return Qnil;
6941
+ fail:
6942
+ return Qnil;
6943
+ }
6944
+
6945
+
6946
+ SWIGINTERN VALUE
6947
+ _wrap_LogitMcState_fym_get(int argc, VALUE *argv, VALUE self) {
6948
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6949
+ double result;
6950
+ void *argp1 = 0 ;
6951
+ int res1 = 0 ;
6952
+ VALUE vresult = Qnil;
6953
+
6954
+ if ((argc < 0) || (argc > 0)) {
6955
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
6956
+ }
6957
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6958
+ if (!SWIG_IsOK(res1)) {
6959
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","fym", 1, self ));
6960
+ }
6961
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6962
+ result = (double) ((arg1)->fym);
6963
+ vresult = SWIG_From_double(static_cast< double >(result));
6964
+ return vresult;
6965
+ fail:
6966
+ return Qnil;
6967
+ }
6968
+
6969
+
6970
+ SWIGINTERN VALUE
6971
+ _wrap_LogitMcState_stx_set(int argc, VALUE *argv, VALUE self) {
6972
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
6973
+ double arg2 ;
6974
+ void *argp1 = 0 ;
6975
+ int res1 = 0 ;
6976
+ double val2 ;
6977
+ int ecode2 = 0 ;
6978
+
6979
+ if ((argc < 1) || (argc > 1)) {
6980
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
6981
+ }
6982
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
6983
+ if (!SWIG_IsOK(res1)) {
6984
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stx", 1, self ));
6985
+ }
6986
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
6987
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
6988
+ if (!SWIG_IsOK(ecode2)) {
6989
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","stx", 2, argv[0] ));
6990
+ }
6991
+ arg2 = static_cast< double >(val2);
6992
+ if (arg1) (arg1)->stx = arg2;
6993
+
6994
+ return Qnil;
6995
+ fail:
6996
+ return Qnil;
6997
+ }
6998
+
6999
+
7000
+ SWIGINTERN VALUE
7001
+ _wrap_LogitMcState_stx_get(int argc, VALUE *argv, VALUE self) {
7002
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7003
+ double result;
7004
+ void *argp1 = 0 ;
7005
+ int res1 = 0 ;
7006
+ VALUE vresult = Qnil;
7007
+
7008
+ if ((argc < 0) || (argc > 0)) {
7009
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7010
+ }
7011
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7012
+ if (!SWIG_IsOK(res1)) {
7013
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stx", 1, self ));
7014
+ }
7015
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7016
+ result = (double) ((arg1)->stx);
7017
+ vresult = SWIG_From_double(static_cast< double >(result));
7018
+ return vresult;
7019
+ fail:
7020
+ return Qnil;
7021
+ }
7022
+
7023
+
7024
+ SWIGINTERN VALUE
7025
+ _wrap_LogitMcState_sty_set(int argc, VALUE *argv, VALUE self) {
7026
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7027
+ double arg2 ;
7028
+ void *argp1 = 0 ;
7029
+ int res1 = 0 ;
7030
+ double val2 ;
7031
+ int ecode2 = 0 ;
7032
+
7033
+ if ((argc < 1) || (argc > 1)) {
7034
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7035
+ }
7036
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7037
+ if (!SWIG_IsOK(res1)) {
7038
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","sty", 1, self ));
7039
+ }
7040
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7041
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7042
+ if (!SWIG_IsOK(ecode2)) {
7043
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","sty", 2, argv[0] ));
7044
+ }
7045
+ arg2 = static_cast< double >(val2);
7046
+ if (arg1) (arg1)->sty = arg2;
7047
+
7048
+ return Qnil;
7049
+ fail:
7050
+ return Qnil;
7051
+ }
7052
+
7053
+
7054
+ SWIGINTERN VALUE
7055
+ _wrap_LogitMcState_sty_get(int argc, VALUE *argv, VALUE self) {
7056
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7057
+ double result;
7058
+ void *argp1 = 0 ;
7059
+ int res1 = 0 ;
7060
+ VALUE vresult = Qnil;
7061
+
7062
+ if ((argc < 0) || (argc > 0)) {
7063
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7064
+ }
7065
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7066
+ if (!SWIG_IsOK(res1)) {
7067
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","sty", 1, self ));
7068
+ }
7069
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7070
+ result = (double) ((arg1)->sty);
7071
+ vresult = SWIG_From_double(static_cast< double >(result));
7072
+ return vresult;
7073
+ fail:
7074
+ return Qnil;
7075
+ }
7076
+
7077
+
7078
+ SWIGINTERN VALUE
7079
+ _wrap_LogitMcState_stmin_set(int argc, VALUE *argv, VALUE self) {
7080
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7081
+ double arg2 ;
7082
+ void *argp1 = 0 ;
7083
+ int res1 = 0 ;
7084
+ double val2 ;
7085
+ int ecode2 = 0 ;
7086
+
7087
+ if ((argc < 1) || (argc > 1)) {
7088
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7089
+ }
7090
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7091
+ if (!SWIG_IsOK(res1)) {
7092
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stmin", 1, self ));
7093
+ }
7094
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7095
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7096
+ if (!SWIG_IsOK(ecode2)) {
7097
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","stmin", 2, argv[0] ));
7098
+ }
7099
+ arg2 = static_cast< double >(val2);
7100
+ if (arg1) (arg1)->stmin = arg2;
7101
+
7102
+ return Qnil;
7103
+ fail:
7104
+ return Qnil;
7105
+ }
7106
+
7107
+
7108
+ SWIGINTERN VALUE
7109
+ _wrap_LogitMcState_stmin_get(int argc, VALUE *argv, VALUE self) {
7110
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7111
+ double result;
7112
+ void *argp1 = 0 ;
7113
+ int res1 = 0 ;
7114
+ VALUE vresult = Qnil;
7115
+
7116
+ if ((argc < 0) || (argc > 0)) {
7117
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7118
+ }
7119
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7120
+ if (!SWIG_IsOK(res1)) {
7121
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stmin", 1, self ));
7122
+ }
7123
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7124
+ result = (double) ((arg1)->stmin);
7125
+ vresult = SWIG_From_double(static_cast< double >(result));
7126
+ return vresult;
7127
+ fail:
7128
+ return Qnil;
7129
+ }
7130
+
7131
+
7132
+ SWIGINTERN VALUE
7133
+ _wrap_LogitMcState_stmax_set(int argc, VALUE *argv, VALUE self) {
7134
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7135
+ double arg2 ;
7136
+ void *argp1 = 0 ;
7137
+ int res1 = 0 ;
7138
+ double val2 ;
7139
+ int ecode2 = 0 ;
7140
+
7141
+ if ((argc < 1) || (argc > 1)) {
7142
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7143
+ }
7144
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7145
+ if (!SWIG_IsOK(res1)) {
7146
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stmax", 1, self ));
7147
+ }
7148
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7149
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7150
+ if (!SWIG_IsOK(ecode2)) {
7151
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","stmax", 2, argv[0] ));
7152
+ }
7153
+ arg2 = static_cast< double >(val2);
7154
+ if (arg1) (arg1)->stmax = arg2;
7155
+
7156
+ return Qnil;
7157
+ fail:
7158
+ return Qnil;
7159
+ }
7160
+
7161
+
7162
+ SWIGINTERN VALUE
7163
+ _wrap_LogitMcState_stmax_get(int argc, VALUE *argv, VALUE self) {
7164
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7165
+ double result;
7166
+ void *argp1 = 0 ;
7167
+ int res1 = 0 ;
7168
+ VALUE vresult = Qnil;
7169
+
7170
+ if ((argc < 0) || (argc > 0)) {
7171
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7172
+ }
7173
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7174
+ if (!SWIG_IsOK(res1)) {
7175
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","stmax", 1, self ));
7176
+ }
7177
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7178
+ result = (double) ((arg1)->stmax);
7179
+ vresult = SWIG_From_double(static_cast< double >(result));
7180
+ return vresult;
7181
+ fail:
7182
+ return Qnil;
7183
+ }
7184
+
7185
+
7186
+ SWIGINTERN VALUE
7187
+ _wrap_LogitMcState_width_set(int argc, VALUE *argv, VALUE self) {
7188
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7189
+ double arg2 ;
7190
+ void *argp1 = 0 ;
7191
+ int res1 = 0 ;
7192
+ double val2 ;
7193
+ int ecode2 = 0 ;
7194
+
7195
+ if ((argc < 1) || (argc > 1)) {
7196
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7197
+ }
7198
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7199
+ if (!SWIG_IsOK(res1)) {
7200
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","width", 1, self ));
7201
+ }
7202
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7203
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7204
+ if (!SWIG_IsOK(ecode2)) {
7205
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","width", 2, argv[0] ));
7206
+ }
7207
+ arg2 = static_cast< double >(val2);
7208
+ if (arg1) (arg1)->width = arg2;
7209
+
7210
+ return Qnil;
7211
+ fail:
7212
+ return Qnil;
7213
+ }
7214
+
7215
+
7216
+ SWIGINTERN VALUE
7217
+ _wrap_LogitMcState_width_get(int argc, VALUE *argv, VALUE self) {
7218
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7219
+ double result;
7220
+ void *argp1 = 0 ;
7221
+ int res1 = 0 ;
7222
+ VALUE vresult = Qnil;
7223
+
7224
+ if ((argc < 0) || (argc > 0)) {
7225
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7226
+ }
7227
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7228
+ if (!SWIG_IsOK(res1)) {
7229
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","width", 1, self ));
7230
+ }
7231
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7232
+ result = (double) ((arg1)->width);
7233
+ vresult = SWIG_From_double(static_cast< double >(result));
7234
+ return vresult;
7235
+ fail:
7236
+ return Qnil;
7237
+ }
7238
+
7239
+
7240
+ SWIGINTERN VALUE
7241
+ _wrap_LogitMcState_width1_set(int argc, VALUE *argv, VALUE self) {
7242
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7243
+ double arg2 ;
7244
+ void *argp1 = 0 ;
7245
+ int res1 = 0 ;
7246
+ double val2 ;
7247
+ int ecode2 = 0 ;
7248
+
7249
+ if ((argc < 1) || (argc > 1)) {
7250
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7251
+ }
7252
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7253
+ if (!SWIG_IsOK(res1)) {
7254
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","width1", 1, self ));
7255
+ }
7256
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7257
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7258
+ if (!SWIG_IsOK(ecode2)) {
7259
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","width1", 2, argv[0] ));
7260
+ }
7261
+ arg2 = static_cast< double >(val2);
7262
+ if (arg1) (arg1)->width1 = arg2;
7263
+
7264
+ return Qnil;
7265
+ fail:
7266
+ return Qnil;
7267
+ }
7268
+
7269
+
7270
+ SWIGINTERN VALUE
7271
+ _wrap_LogitMcState_width1_get(int argc, VALUE *argv, VALUE self) {
7272
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7273
+ double result;
7274
+ void *argp1 = 0 ;
7275
+ int res1 = 0 ;
7276
+ VALUE vresult = Qnil;
7277
+
7278
+ if ((argc < 0) || (argc > 0)) {
7279
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7280
+ }
7281
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7282
+ if (!SWIG_IsOK(res1)) {
7283
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","width1", 1, self ));
7284
+ }
7285
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7286
+ result = (double) ((arg1)->width1);
7287
+ vresult = SWIG_From_double(static_cast< double >(result));
7288
+ return vresult;
7289
+ fail:
7290
+ return Qnil;
7291
+ }
7292
+
7293
+
7294
+ SWIGINTERN VALUE
7295
+ _wrap_LogitMcState_xtrapf_set(int argc, VALUE *argv, VALUE self) {
7296
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7297
+ double arg2 ;
7298
+ void *argp1 = 0 ;
7299
+ int res1 = 0 ;
7300
+ double val2 ;
7301
+ int ecode2 = 0 ;
7302
+
7303
+ if ((argc < 1) || (argc > 1)) {
7304
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7305
+ }
7306
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7307
+ if (!SWIG_IsOK(res1)) {
7308
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","xtrapf", 1, self ));
7309
+ }
7310
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7311
+ ecode2 = SWIG_AsVal_double(argv[0], &val2);
7312
+ if (!SWIG_IsOK(ecode2)) {
7313
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "double","xtrapf", 2, argv[0] ));
7314
+ }
7315
+ arg2 = static_cast< double >(val2);
7316
+ if (arg1) (arg1)->xtrapf = arg2;
7317
+
7318
+ return Qnil;
7319
+ fail:
7320
+ return Qnil;
7321
+ }
7322
+
7323
+
7324
+ SWIGINTERN VALUE
7325
+ _wrap_LogitMcState_xtrapf_get(int argc, VALUE *argv, VALUE self) {
7326
+ logitmcstate *arg1 = (logitmcstate *) 0 ;
7327
+ double result;
7328
+ void *argp1 = 0 ;
7329
+ int res1 = 0 ;
7330
+ VALUE vresult = Qnil;
7331
+
7332
+ if ((argc < 0) || (argc > 0)) {
7333
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7334
+ }
7335
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_logitmcstate, 0 | 0 );
7336
+ if (!SWIG_IsOK(res1)) {
7337
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmcstate *","xtrapf", 1, self ));
7338
+ }
7339
+ arg1 = reinterpret_cast< logitmcstate * >(argp1);
7340
+ result = (double) ((arg1)->xtrapf);
7341
+ vresult = SWIG_From_double(static_cast< double >(result));
7342
+ return vresult;
7343
+ fail:
7344
+ return Qnil;
7345
+ }
7346
+
7347
+
7348
+ #ifdef HAVE_RB_DEFINE_ALLOC_FUNC
7349
+ SWIGINTERN VALUE
7350
+ _wrap_LogitMcState_allocate(VALUE self) {
7351
+ #else
7352
+ SWIGINTERN VALUE
7353
+ _wrap_LogitMcState_allocate(int argc, VALUE *argv, VALUE self) {
7354
+ #endif
7355
+
7356
+
7357
+ VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_logitmcstate);
7358
+ #ifndef HAVE_RB_DEFINE_ALLOC_FUNC
7359
+ rb_obj_call_init(vresult, argc, argv);
7360
+ #endif
7361
+ return vresult;
7362
+ }
7363
+
7364
+
7365
+ SWIGINTERN VALUE
7366
+ _wrap_new_LogitMcState(int argc, VALUE *argv, VALUE self) {
7367
+ logitmcstate *result = 0 ;
7368
+
7369
+ if ((argc < 0) || (argc > 0)) {
7370
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7371
+ }
7372
+ result = (logitmcstate *)new logitmcstate();DATA_PTR(self) = result;
7373
+
7374
+ return self;
7375
+ fail:
7376
+ return Qnil;
7377
+ }
7378
+
7379
+
7380
+ SWIGINTERN void
7381
+ free_logitmcstate(logitmcstate *arg1) {
7382
+ delete arg1;
7383
+ }
7384
+
7385
+ swig_class cMNLReport;
7386
+
7387
+ SWIGINTERN VALUE
7388
+ _wrap_MNLReport_ngrad_set(int argc, VALUE *argv, VALUE self) {
7389
+ mnlreport *arg1 = (mnlreport *) 0 ;
7390
+ int arg2 ;
7391
+ void *argp1 = 0 ;
7392
+ int res1 = 0 ;
7393
+ int val2 ;
7394
+ int ecode2 = 0 ;
7395
+
7396
+ if ((argc < 1) || (argc > 1)) {
7397
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7398
+ }
7399
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_mnlreport, 0 | 0 );
7400
+ if (!SWIG_IsOK(res1)) {
7401
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "mnlreport *","ngrad", 1, self ));
7402
+ }
7403
+ arg1 = reinterpret_cast< mnlreport * >(argp1);
7404
+ ecode2 = SWIG_AsVal_int(argv[0], &val2);
7405
+ if (!SWIG_IsOK(ecode2)) {
7406
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","ngrad", 2, argv[0] ));
7407
+ }
7408
+ arg2 = static_cast< int >(val2);
7409
+ if (arg1) (arg1)->ngrad = arg2;
7410
+
7411
+ return Qnil;
7412
+ fail:
7413
+ return Qnil;
7414
+ }
7415
+
7416
+
7417
+ SWIGINTERN VALUE
7418
+ _wrap_MNLReport_ngrad_get(int argc, VALUE *argv, VALUE self) {
7419
+ mnlreport *arg1 = (mnlreport *) 0 ;
7420
+ int result;
7421
+ void *argp1 = 0 ;
7422
+ int res1 = 0 ;
7423
+ VALUE vresult = Qnil;
7424
+
7425
+ if ((argc < 0) || (argc > 0)) {
7426
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7427
+ }
7428
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_mnlreport, 0 | 0 );
7429
+ if (!SWIG_IsOK(res1)) {
7430
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "mnlreport *","ngrad", 1, self ));
7431
+ }
7432
+ arg1 = reinterpret_cast< mnlreport * >(argp1);
7433
+ result = (int) ((arg1)->ngrad);
7434
+ vresult = SWIG_From_int(static_cast< int >(result));
7435
+ return vresult;
7436
+ fail:
7437
+ return Qnil;
7438
+ }
7439
+
7440
+
7441
+ SWIGINTERN VALUE
7442
+ _wrap_MNLReport_nhess_set(int argc, VALUE *argv, VALUE self) {
7443
+ mnlreport *arg1 = (mnlreport *) 0 ;
7444
+ int arg2 ;
7445
+ void *argp1 = 0 ;
7446
+ int res1 = 0 ;
7447
+ int val2 ;
7448
+ int ecode2 = 0 ;
7449
+
7450
+ if ((argc < 1) || (argc > 1)) {
7451
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
7452
+ }
7453
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_mnlreport, 0 | 0 );
7454
+ if (!SWIG_IsOK(res1)) {
7455
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "mnlreport *","nhess", 1, self ));
7456
+ }
7457
+ arg1 = reinterpret_cast< mnlreport * >(argp1);
7458
+ ecode2 = SWIG_AsVal_int(argv[0], &val2);
7459
+ if (!SWIG_IsOK(ecode2)) {
7460
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","nhess", 2, argv[0] ));
7461
+ }
7462
+ arg2 = static_cast< int >(val2);
7463
+ if (arg1) (arg1)->nhess = arg2;
7464
+
7465
+ return Qnil;
7466
+ fail:
7467
+ return Qnil;
7468
+ }
7469
+
7470
+
7471
+ SWIGINTERN VALUE
7472
+ _wrap_MNLReport_nhess_get(int argc, VALUE *argv, VALUE self) {
7473
+ mnlreport *arg1 = (mnlreport *) 0 ;
7474
+ int result;
7475
+ void *argp1 = 0 ;
7476
+ int res1 = 0 ;
7477
+ VALUE vresult = Qnil;
7478
+
7479
+ if ((argc < 0) || (argc > 0)) {
7480
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7481
+ }
7482
+ res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_mnlreport, 0 | 0 );
7483
+ if (!SWIG_IsOK(res1)) {
7484
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "mnlreport *","nhess", 1, self ));
7485
+ }
7486
+ arg1 = reinterpret_cast< mnlreport * >(argp1);
7487
+ result = (int) ((arg1)->nhess);
7488
+ vresult = SWIG_From_int(static_cast< int >(result));
7489
+ return vresult;
7490
+ fail:
7491
+ return Qnil;
7492
+ }
7493
+
7494
+
7495
+ #ifdef HAVE_RB_DEFINE_ALLOC_FUNC
7496
+ SWIGINTERN VALUE
7497
+ _wrap_MNLReport_allocate(VALUE self) {
7498
+ #else
7499
+ SWIGINTERN VALUE
7500
+ _wrap_MNLReport_allocate(int argc, VALUE *argv, VALUE self) {
7501
+ #endif
7502
+
7503
+
7504
+ VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_mnlreport);
7505
+ #ifndef HAVE_RB_DEFINE_ALLOC_FUNC
7506
+ rb_obj_call_init(vresult, argc, argv);
7507
+ #endif
7508
+ return vresult;
7509
+ }
7510
+
7511
+
7512
+ SWIGINTERN VALUE
7513
+ _wrap_new_MNLReport(int argc, VALUE *argv, VALUE self) {
7514
+ mnlreport *result = 0 ;
7515
+
7516
+ if ((argc < 0) || (argc > 0)) {
7517
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
7518
+ }
7519
+ result = (mnlreport *)new mnlreport();DATA_PTR(self) = result;
7520
+
7521
+ return self;
7522
+ fail:
7523
+ return Qnil;
7524
+ }
7525
+
7526
+
7527
+ SWIGINTERN void
7528
+ free_mnlreport(mnlreport *arg1) {
7529
+ delete arg1;
7530
+ }
7531
+
7532
+ SWIGINTERN VALUE
7533
+ _wrap_mnltrainh(int argc, VALUE *argv, VALUE self) {
7534
+ ap::real_2d_array *arg1 = 0 ;
7535
+ int arg2 ;
7536
+ int arg3 ;
7537
+ int arg4 ;
7538
+ int *arg5 = 0 ;
7539
+ logitmodel *arg6 = 0 ;
7540
+ mnlreport *arg7 = 0 ;
7541
+ void *argp1 ;
7542
+ int res1 = 0 ;
7543
+ int val2 ;
7544
+ int ecode2 = 0 ;
7545
+ int val3 ;
7546
+ int ecode3 = 0 ;
7547
+ int val4 ;
7548
+ int ecode4 = 0 ;
7549
+ int temp5 ;
7550
+ int res5 = SWIG_TMPOBJ ;
7551
+ void *argp6 = 0 ;
7552
+ int res6 = 0 ;
7553
+ void *argp7 = 0 ;
7554
+ int res7 = 0 ;
7555
+ VALUE vresult = Qnil;
7556
+
7557
+ arg5 = &temp5;
7558
+ if ((argc < 6) || (argc > 6)) {
7559
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 6)",argc); SWIG_fail;
7560
+ }
7561
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_ap__template_2d_arrayT_double_true_t, 0 );
7562
+ if (!SWIG_IsOK(res1)) {
7563
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "ap::real_2d_array const &","mnltrainh", 1, argv[0] ));
7564
+ }
7565
+ if (!argp1) {
7566
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "ap::real_2d_array const &","mnltrainh", 1, argv[0]));
7567
+ }
7568
+ arg1 = reinterpret_cast< ap::real_2d_array * >(argp1);
7569
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
7570
+ if (!SWIG_IsOK(ecode2)) {
7571
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","mnltrainh", 2, argv[1] ));
7572
+ }
7573
+ arg2 = static_cast< int >(val2);
7574
+ ecode3 = SWIG_AsVal_int(argv[2], &val3);
7575
+ if (!SWIG_IsOK(ecode3)) {
7576
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","mnltrainh", 3, argv[2] ));
7577
+ }
7578
+ arg3 = static_cast< int >(val3);
7579
+ ecode4 = SWIG_AsVal_int(argv[3], &val4);
7580
+ if (!SWIG_IsOK(ecode4)) {
7581
+ SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "int","mnltrainh", 4, argv[3] ));
7582
+ }
7583
+ arg4 = static_cast< int >(val4);
7584
+ res6 = SWIG_ConvertPtr(argv[4], &argp6, SWIGTYPE_p_logitmodel, 0 );
7585
+ if (!SWIG_IsOK(res6)) {
7586
+ SWIG_exception_fail(SWIG_ArgError(res6), Ruby_Format_TypeError( "", "logitmodel &","mnltrainh", 6, argv[4] ));
7587
+ }
7588
+ if (!argp6) {
7589
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","mnltrainh", 6, argv[4]));
7590
+ }
7591
+ arg6 = reinterpret_cast< logitmodel * >(argp6);
7592
+ res7 = SWIG_ConvertPtr(argv[5], &argp7, SWIGTYPE_p_mnlreport, 0 );
7593
+ if (!SWIG_IsOK(res7)) {
7594
+ SWIG_exception_fail(SWIG_ArgError(res7), Ruby_Format_TypeError( "", "mnlreport &","mnltrainh", 7, argv[5] ));
7595
+ }
7596
+ if (!argp7) {
7597
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "mnlreport &","mnltrainh", 7, argv[5]));
7598
+ }
7599
+ arg7 = reinterpret_cast< mnlreport * >(argp7);
7600
+ mnltrainh((ap::template_2d_array< double,true > const &)*arg1,arg2,arg3,arg4,*arg5,*arg6,*arg7);
7601
+ if (SWIG_IsTmpObj(res5)) {
7602
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_From_int((*arg5)));
7603
+ } else {
7604
+ int new_flags = SWIG_IsNewObj(res5) ? (SWIG_POINTER_OWN | 0 ) : 0 ;
7605
+ vresult = SWIG_Ruby_AppendOutput(vresult, SWIG_NewPointerObj((void*)(arg5), SWIGTYPE_p_int, new_flags));
7606
+ }
7607
+ return vresult;
7608
+ fail:
7609
+ return Qnil;
7610
+ }
7611
+
7612
+
7613
+ SWIGINTERN VALUE
7614
+ _wrap_mnlprocess(int argc, VALUE *argv, VALUE self) {
7615
+ logitmodel *arg1 = 0 ;
7616
+ ap::real_1d_array *arg2 = 0 ;
7617
+ VALUE result;
7618
+ void *argp1 = 0 ;
7619
+ int res1 = 0 ;
7620
+ VALUE vresult = Qnil;
7621
+
7622
+ if ((argc < 2) || (argc > 2)) {
7623
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
7624
+ }
7625
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_logitmodel, 0 );
7626
+ if (!SWIG_IsOK(res1)) {
7627
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel &","wrap_mnlprocess", 1, argv[0] ));
7628
+ }
7629
+ if (!argp1) {
7630
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","wrap_mnlprocess", 1, argv[0]));
7631
+ }
7632
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
7633
+ {
7634
+ arg2 = new ap::real_1d_array();
7635
+ arg2->setlength(RARRAY_LEN(argv[1]));
7636
+ for(long i=0;i<RARRAY_LEN(argv[1]);i++) {
7637
+ arg2->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[1])[i]);
7638
+ }
7639
+ }
7640
+ result = (VALUE)wrap_mnlprocess(*arg1,(ap::template_1d_array< double,true > const &)*arg2);
7641
+ vresult = result;
7642
+ return vresult;
7643
+ fail:
7644
+ return Qnil;
7645
+ }
7646
+
7647
+
7648
+ SWIGINTERN VALUE
7649
+ _wrap_mnlunpack(int argc, VALUE *argv, VALUE self) {
7650
+ logitmodel *arg1 = 0 ;
7651
+ ap::real_2d_array *arg2 = 0 ;
7652
+ int *arg3 = 0 ;
7653
+ int *arg4 = 0 ;
7654
+ void *argp1 ;
7655
+ int res1 = 0 ;
7656
+ void *argp2 = 0 ;
7657
+ int res2 = 0 ;
7658
+ int temp3 ;
7659
+ int res3 = 0 ;
7660
+ int temp4 ;
7661
+ int res4 = 0 ;
7662
+
7663
+ if ((argc < 4) || (argc > 4)) {
7664
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
7665
+ }
7666
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_logitmodel, 0 );
7667
+ if (!SWIG_IsOK(res1)) {
7668
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel const &","mnlunpack", 1, argv[0] ));
7669
+ }
7670
+ if (!argp1) {
7671
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel const &","mnlunpack", 1, argv[0]));
7672
+ }
7673
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
7674
+ res2 = SWIG_ConvertPtr(argv[1], &argp2, SWIGTYPE_p_ap__template_2d_arrayT_double_true_t, 0 );
7675
+ if (!SWIG_IsOK(res2)) {
7676
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "ap::real_2d_array &","mnlunpack", 2, argv[1] ));
7677
+ }
7678
+ if (!argp2) {
7679
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "ap::real_2d_array &","mnlunpack", 2, argv[1]));
7680
+ }
7681
+ arg2 = reinterpret_cast< ap::real_2d_array * >(argp2);
7682
+ if (!(SWIG_IsOK((res3 = SWIG_ConvertPtr(argv[2],SWIG_as_voidptrptr(&arg3),SWIGTYPE_p_int,0))))) {
7683
+ int val;
7684
+ int ecode = SWIG_AsVal_int(argv[2], &val);
7685
+ if (!SWIG_IsOK(ecode)) {
7686
+ SWIG_exception_fail(SWIG_ArgError(ecode), Ruby_Format_TypeError( "", "int","mnlunpack", 3, argv[2] ));
7687
+ }
7688
+ temp3 = static_cast< int >(val);
7689
+ arg3 = &temp3;
7690
+ res3 = SWIG_AddTmpMask(ecode);
7691
+ }
7692
+ if (!(SWIG_IsOK((res4 = SWIG_ConvertPtr(argv[3],SWIG_as_voidptrptr(&arg4),SWIGTYPE_p_int,0))))) {
7693
+ int val;
7694
+ int ecode = SWIG_AsVal_int(argv[3], &val);
7695
+ if (!SWIG_IsOK(ecode)) {
7696
+ SWIG_exception_fail(SWIG_ArgError(ecode), Ruby_Format_TypeError( "", "int","mnlunpack", 4, argv[3] ));
7697
+ }
7698
+ temp4 = static_cast< int >(val);
7699
+ arg4 = &temp4;
7700
+ res4 = SWIG_AddTmpMask(ecode);
7701
+ }
7702
+ mnlunpack((logitmodel const &)*arg1,*arg2,*arg3,*arg4);
7703
+ if (SWIG_IsNewObj(res3)) delete arg3;
7704
+ if (SWIG_IsNewObj(res4)) delete arg4;
7705
+ return Qnil;
7706
+ fail:
7707
+ if (SWIG_IsNewObj(res3)) delete arg3;
7708
+ if (SWIG_IsNewObj(res4)) delete arg4;
7709
+ return Qnil;
7710
+ }
7711
+
7712
+
7713
+ SWIGINTERN VALUE
7714
+ _wrap_mnlpack(int argc, VALUE *argv, VALUE self) {
7715
+ ap::real_2d_array *arg1 = 0 ;
7716
+ int arg2 ;
7717
+ int arg3 ;
7718
+ logitmodel *arg4 = 0 ;
7719
+ void *argp1 ;
7720
+ int res1 = 0 ;
7721
+ int val2 ;
7722
+ int ecode2 = 0 ;
7723
+ int val3 ;
7724
+ int ecode3 = 0 ;
7725
+ void *argp4 = 0 ;
7726
+ int res4 = 0 ;
7727
+
7728
+ if ((argc < 4) || (argc > 4)) {
7729
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
7730
+ }
7731
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_ap__template_2d_arrayT_double_true_t, 0 );
7732
+ if (!SWIG_IsOK(res1)) {
7733
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "ap::real_2d_array const &","mnlpack", 1, argv[0] ));
7734
+ }
7735
+ if (!argp1) {
7736
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "ap::real_2d_array const &","mnlpack", 1, argv[0]));
7737
+ }
7738
+ arg1 = reinterpret_cast< ap::real_2d_array * >(argp1);
7739
+ ecode2 = SWIG_AsVal_int(argv[1], &val2);
7740
+ if (!SWIG_IsOK(ecode2)) {
7741
+ SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","mnlpack", 2, argv[1] ));
7742
+ }
7743
+ arg2 = static_cast< int >(val2);
7744
+ ecode3 = SWIG_AsVal_int(argv[2], &val3);
7745
+ if (!SWIG_IsOK(ecode3)) {
7746
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","mnlpack", 3, argv[2] ));
7747
+ }
7748
+ arg3 = static_cast< int >(val3);
7749
+ res4 = SWIG_ConvertPtr(argv[3], &argp4, SWIGTYPE_p_logitmodel, 0 );
7750
+ if (!SWIG_IsOK(res4)) {
7751
+ SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "logitmodel &","mnlpack", 4, argv[3] ));
7752
+ }
7753
+ if (!argp4) {
7754
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","mnlpack", 4, argv[3]));
7755
+ }
7756
+ arg4 = reinterpret_cast< logitmodel * >(argp4);
7757
+ mnlpack((ap::template_2d_array< double,true > const &)*arg1,arg2,arg3,*arg4);
7758
+ return Qnil;
7759
+ fail:
7760
+ return Qnil;
7761
+ }
7762
+
7763
+
7764
+ SWIGINTERN VALUE
7765
+ _wrap_mnlserialize(int argc, VALUE *argv, VALUE self) {
7766
+ logitmodel *arg1 = 0 ;
7767
+ ap::real_1d_array *arg2 = 0 ;
7768
+ int *arg3 = 0 ;
7769
+ void *argp1 ;
7770
+ int res1 = 0 ;
7771
+ void *argp2 = 0 ;
7772
+ int res2 = 0 ;
7773
+ void *argp3 = 0 ;
7774
+ int res3 = 0 ;
7775
+
7776
+ if ((argc < 3) || (argc > 3)) {
7777
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
7778
+ }
7779
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_logitmodel, 0 );
7780
+ if (!SWIG_IsOK(res1)) {
7781
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel const &","mnlserialize", 1, argv[0] ));
7782
+ }
7783
+ if (!argp1) {
7784
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel const &","mnlserialize", 1, argv[0]));
7785
+ }
7786
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
7787
+ res2 = SWIG_ConvertPtr(argv[1], &argp2, SWIGTYPE_p_ap__template_1d_arrayT_double_true_t, 0 );
7788
+ if (!SWIG_IsOK(res2)) {
7789
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "ap::real_1d_array &","mnlserialize", 2, argv[1] ));
7790
+ }
7791
+ if (!argp2) {
7792
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "ap::real_1d_array &","mnlserialize", 2, argv[1]));
7793
+ }
7794
+ arg2 = reinterpret_cast< ap::real_1d_array * >(argp2);
7795
+ res3 = SWIG_ConvertPtr(argv[2], &argp3, SWIGTYPE_p_int, 0 );
7796
+ if (!SWIG_IsOK(res3)) {
7797
+ SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int &","mnlserialize", 3, argv[2] ));
7798
+ }
7799
+ if (!argp3) {
7800
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int &","mnlserialize", 3, argv[2]));
7801
+ }
7802
+ arg3 = reinterpret_cast< int * >(argp3);
7803
+ mnlserialize((logitmodel const &)*arg1,*arg2,*arg3);
7804
+ return Qnil;
7805
+ fail:
7806
+ return Qnil;
7807
+ }
7808
+
7809
+
7810
+ SWIGINTERN VALUE
7811
+ _wrap_mnlcopy(int argc, VALUE *argv, VALUE self) {
7812
+ logitmodel *arg1 = 0 ;
7813
+ logitmodel *arg2 = 0 ;
7814
+ void *argp1 ;
7815
+ int res1 = 0 ;
7816
+ void *argp2 = 0 ;
7817
+ int res2 = 0 ;
7818
+
7819
+ if ((argc < 2) || (argc > 2)) {
7820
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
7821
+ }
7822
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_logitmodel, 0 );
7823
+ if (!SWIG_IsOK(res1)) {
7824
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel const &","mnlcopy", 1, argv[0] ));
7825
+ }
7826
+ if (!argp1) {
7827
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel const &","mnlcopy", 1, argv[0]));
7828
+ }
7829
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
7830
+ res2 = SWIG_ConvertPtr(argv[1], &argp2, SWIGTYPE_p_logitmodel, 0 );
7831
+ if (!SWIG_IsOK(res2)) {
7832
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "logitmodel &","mnlcopy", 2, argv[1] ));
7833
+ }
7834
+ if (!argp2) {
7835
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","mnlcopy", 2, argv[1]));
7836
+ }
7837
+ arg2 = reinterpret_cast< logitmodel * >(argp2);
7838
+ mnlcopy((logitmodel const &)*arg1,*arg2);
7839
+ return Qnil;
7840
+ fail:
7841
+ return Qnil;
7842
+ }
7843
+
7844
+
7845
+ SWIGINTERN VALUE
7846
+ _wrap_mnlunserialize(int argc, VALUE *argv, VALUE self) {
7847
+ ap::real_1d_array *arg1 = 0 ;
7848
+ logitmodel *arg2 = 0 ;
7849
+ void *argp2 = 0 ;
7850
+ int res2 = 0 ;
7851
+
7852
+ if ((argc < 2) || (argc > 2)) {
7853
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
7854
+ }
7855
+ {
7856
+ arg1 = new ap::real_1d_array();
7857
+ arg1->setlength(RARRAY_LEN(argv[0]));
7858
+ for(long i=0;i<RARRAY_LEN(argv[0]);i++) {
7859
+ arg1->operator()(i)=rb_num2dbl(RARRAY_PTR(argv[0])[i]);
7860
+ }
7861
+ }
7862
+ res2 = SWIG_ConvertPtr(argv[1], &argp2, SWIGTYPE_p_logitmodel, 0 );
7863
+ if (!SWIG_IsOK(res2)) {
7864
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "logitmodel &","mnlunserialize", 2, argv[1] ));
7865
+ }
7866
+ if (!argp2) {
7867
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","mnlunserialize", 2, argv[1]));
7868
+ }
7869
+ arg2 = reinterpret_cast< logitmodel * >(argp2);
7870
+ mnlunserialize((ap::template_1d_array< double,true > const &)*arg1,*arg2);
7871
+ return Qnil;
7872
+ fail:
7873
+ return Qnil;
7874
+ }
7875
+
7876
+
7877
+ SWIGINTERN VALUE
7878
+ _wrap_mnlavgce(int argc, VALUE *argv, VALUE self) {
7879
+ logitmodel *arg1 = 0 ;
7880
+ ap::real_2d_array *arg2 = 0 ;
7881
+ int arg3 ;
7882
+ double result;
7883
+ void *argp1 = 0 ;
7884
+ int res1 = 0 ;
7885
+ void *argp2 ;
7886
+ int res2 = 0 ;
7887
+ int val3 ;
7888
+ int ecode3 = 0 ;
7889
+ VALUE vresult = Qnil;
7890
+
7891
+ if ((argc < 3) || (argc > 3)) {
7892
+ rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
7893
+ }
7894
+ res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_logitmodel, 0 );
7895
+ if (!SWIG_IsOK(res1)) {
7896
+ SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "logitmodel &","mnlavgce", 1, argv[0] ));
7897
+ }
7898
+ if (!argp1) {
7899
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "logitmodel &","mnlavgce", 1, argv[0]));
7900
+ }
7901
+ arg1 = reinterpret_cast< logitmodel * >(argp1);
7902
+ res2 = SWIG_ConvertPtr(argv[1], &argp2, SWIGTYPE_p_ap__template_2d_arrayT_double_true_t, 0 );
7903
+ if (!SWIG_IsOK(res2)) {
7904
+ SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "ap::real_2d_array const &","mnlavgce", 2, argv[1] ));
7905
+ }
7906
+ if (!argp2) {
7907
+ SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "ap::real_2d_array const &","mnlavgce", 2, argv[1]));
7908
+ }
7909
+ arg2 = reinterpret_cast< ap::real_2d_array * >(argp2);
7910
+ ecode3 = SWIG_AsVal_int(argv[2], &val3);
7911
+ if (!SWIG_IsOK(ecode3)) {
7912
+ SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","mnlavgce", 3, argv[2] ));
7913
+ }
7914
+ arg3 = static_cast< int >(val3);
7915
+ result = (double)mnlavgce(*arg1,(ap::template_2d_array< double,true > const &)*arg2,arg3);
7916
+ vresult = SWIG_From_double(static_cast< double >(result));
7917
+ return vresult;
7918
+ fail:
7919
+ return Qnil;
7920
+ }
7921
+
7922
+
7923
+
7924
+ /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
7925
+
7926
+ static swig_type_info _swigt__p_ap__template_1d_arrayT_bool_false_t = {"_p_ap__template_1d_arrayT_bool_false_t", "ap::boolean_1d_array *|ap::template_1d_array< bool > *|ap::template_1d_array< bool,false > *", 0, 0, (void*)0, 0};
7927
+ static swig_type_info _swigt__p_ap__template_1d_arrayT_complex_false_t = {"_p_ap__template_1d_arrayT_complex_false_t", "ap::complex_1d_array *|ap::template_1d_array< complex,false > *", 0, 0, (void*)0, 0};
7928
+ static swig_type_info _swigt__p_ap__template_1d_arrayT_double_true_t = {"_p_ap__template_1d_arrayT_double_true_t", "ap::real_1d_array *|ap::template_1d_array< double,true > *", 0, 0, (void*)0, 0};
7929
+ static swig_type_info _swigt__p_ap__template_1d_arrayT_int_false_t = {"_p_ap__template_1d_arrayT_int_false_t", "ap::integer_1d_array *|ap::template_1d_array< int > *|ap::template_1d_array< int,false > *", 0, 0, (void*)0, 0};
7930
+ static swig_type_info _swigt__p_ap__template_2d_arrayT_bool_false_t = {"_p_ap__template_2d_arrayT_bool_false_t", "ap::boolean_2d_array *|ap::template_2d_array< bool,false > *", 0, 0, (void*)0, 0};
7931
+ static swig_type_info _swigt__p_ap__template_2d_arrayT_complex_false_t = {"_p_ap__template_2d_arrayT_complex_false_t", "ap::complex_2d_array *|ap::template_2d_array< complex,false > *", 0, 0, (void*)0, 0};
7932
+ static swig_type_info _swigt__p_ap__template_2d_arrayT_double_true_t = {"_p_ap__template_2d_arrayT_double_true_t", "ap::real_2d_array *|ap::template_2d_array< double,true > *", 0, 0, (void*)0, 0};
7933
+ static swig_type_info _swigt__p_ap__template_2d_arrayT_int_false_t = {"_p_ap__template_2d_arrayT_int_false_t", "ap::integer_2d_array *|ap::template_2d_array< int > *|ap::template_2d_array< int,false > *", 0, 0, (void*)0, 0};
7934
+ static swig_type_info _swigt__p_bool = {"_p_bool", "bool *", 0, 0, (void*)0, 0};
7935
+ static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
7936
+ static swig_type_info _swigt__p_double = {"_p_double", "double *", 0, 0, (void*)0, 0};
7937
+ static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, (void*)0, 0};
7938
+ static swig_type_info _swigt__p_linearmodel = {"_p_linearmodel", "linearmodel *", 0, 0, (void*)0, 0};
7939
+ static swig_type_info _swigt__p_logitmcstate = {"_p_logitmcstate", "logitmcstate *", 0, 0, (void*)0, 0};
7940
+ static swig_type_info _swigt__p_logitmodel = {"_p_logitmodel", "logitmodel *", 0, 0, (void*)0, 0};
7941
+ static swig_type_info _swigt__p_lrreport = {"_p_lrreport", "lrreport *", 0, 0, (void*)0, 0};
7942
+ static swig_type_info _swigt__p_mnlreport = {"_p_mnlreport", "mnlreport *", 0, 0, (void*)0, 0};
7943
+
7944
+ static swig_type_info *swig_type_initial[] = {
7945
+ &_swigt__p_ap__template_1d_arrayT_bool_false_t,
7946
+ &_swigt__p_ap__template_1d_arrayT_complex_false_t,
7947
+ &_swigt__p_ap__template_1d_arrayT_double_true_t,
7948
+ &_swigt__p_ap__template_1d_arrayT_int_false_t,
7949
+ &_swigt__p_ap__template_2d_arrayT_bool_false_t,
7950
+ &_swigt__p_ap__template_2d_arrayT_complex_false_t,
5698
7951
  &_swigt__p_ap__template_2d_arrayT_double_true_t,
5699
7952
  &_swigt__p_ap__template_2d_arrayT_int_false_t,
5700
7953
  &_swigt__p_bool,
@@ -5702,7 +7955,10 @@ static swig_type_info *swig_type_initial[] = {
5702
7955
  &_swigt__p_double,
5703
7956
  &_swigt__p_int,
5704
7957
  &_swigt__p_linearmodel,
7958
+ &_swigt__p_logitmcstate,
7959
+ &_swigt__p_logitmodel,
5705
7960
  &_swigt__p_lrreport,
7961
+ &_swigt__p_mnlreport,
5706
7962
  };
5707
7963
 
5708
7964
  static swig_cast_info _swigc__p_ap__template_1d_arrayT_bool_false_t[] = { {&_swigt__p_ap__template_1d_arrayT_bool_false_t, 0, 0, 0},{0, 0, 0, 0}};
@@ -5718,7 +7974,10 @@ static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0,
5718
7974
  static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}};
5719
7975
  static swig_cast_info _swigc__p_int[] = { {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
5720
7976
  static swig_cast_info _swigc__p_linearmodel[] = { {&_swigt__p_linearmodel, 0, 0, 0},{0, 0, 0, 0}};
7977
+ static swig_cast_info _swigc__p_logitmcstate[] = { {&_swigt__p_logitmcstate, 0, 0, 0},{0, 0, 0, 0}};
7978
+ static swig_cast_info _swigc__p_logitmodel[] = { {&_swigt__p_logitmodel, 0, 0, 0},{0, 0, 0, 0}};
5721
7979
  static swig_cast_info _swigc__p_lrreport[] = { {&_swigt__p_lrreport, 0, 0, 0},{0, 0, 0, 0}};
7980
+ static swig_cast_info _swigc__p_mnlreport[] = { {&_swigt__p_mnlreport, 0, 0, 0},{0, 0, 0, 0}};
5722
7981
 
5723
7982
  static swig_cast_info *swig_cast_initial[] = {
5724
7983
  _swigc__p_ap__template_1d_arrayT_bool_false_t,
@@ -5734,7 +7993,10 @@ static swig_cast_info *swig_cast_initial[] = {
5734
7993
  _swigc__p_double,
5735
7994
  _swigc__p_int,
5736
7995
  _swigc__p_linearmodel,
7996
+ _swigc__p_logitmcstate,
7997
+ _swigc__p_logitmodel,
5737
7998
  _swigc__p_lrreport,
7999
+ _swigc__p_mnlreport,
5738
8000
  };
5739
8001
 
5740
8002
 
@@ -6078,6 +8340,12 @@ SWIGEXPORT void Init_alglib_ext(void) {
6078
8340
  cReal2dArray.mark = 0;
6079
8341
  cReal2dArray.destroy = (void (*)(void *)) free_ap_template_2d_array_Sl_double_Sc_true_Sg_;
6080
8342
  cReal2dArray.trackObjects = 0;
8343
+ rb_define_module_function(mAlglib_ext, "real1d_to_array", VALUEFUNC(_wrap_real1d_to_array), -1);
8344
+ rb_define_module_function(mAlglib_ext, "array_to_real1d", VALUEFUNC(_wrap_array_to_real1d), -1);
8345
+ rb_define_module_function(mAlglib_ext, "pearsoncorrelation", VALUEFUNC(_wrap_pearsoncorrelation), -1);
8346
+ rb_define_module_function(mAlglib_ext, "spearmanrankcorrelation", VALUEFUNC(_wrap_spearmanrankcorrelation), -1);
8347
+ rb_define_module_function(mAlglib_ext, "pearsoncorrelationsignificance", VALUEFUNC(_wrap_pearsoncorrelationsignificance), -1);
8348
+ rb_define_module_function(mAlglib_ext, "spearmanrankcorrelationsignificance", VALUEFUNC(_wrap_spearmanrankcorrelationsignificance), -1);
6081
8349
 
6082
8350
  cLinearModel.klass = rb_define_class_under(mAlglib_ext, "LinearModel", rb_cObject);
6083
8351
  SWIG_TypeClientData(SWIGTYPE_p_linearmodel, (void *) &cLinearModel);
@@ -6121,6 +8389,93 @@ SWIGEXPORT void Init_alglib_ext(void) {
6121
8389
  rb_define_module_function(mAlglib_ext, "lrunpack", VALUEFUNC(_wrap_lrunpack), -1);
6122
8390
  rb_define_module_function(mAlglib_ext, "lrpack", VALUEFUNC(_wrap_lrpack), -1);
6123
8391
  rb_define_module_function(mAlglib_ext, "lrprocess", VALUEFUNC(_wrap_lrprocess), -1);
6124
- rb_define_module_function(mAlglib_ext, "real1d_to_array", VALUEFUNC(_wrap_real1d_to_array), -1);
8392
+
8393
+ cLogitModel.klass = rb_define_class_under(mAlglib_ext, "LogitModel", rb_cObject);
8394
+ SWIG_TypeClientData(SWIGTYPE_p_logitmodel, (void *) &cLogitModel);
8395
+ rb_define_alloc_func(cLogitModel.klass, _wrap_LogitModel_allocate);
8396
+ rb_define_method(cLogitModel.klass, "initialize", VALUEFUNC(_wrap_new_LogitModel), -1);
8397
+ rb_define_method(cLogitModel.klass, "w=", VALUEFUNC(_wrap_LogitModel_w_set), -1);
8398
+ rb_define_method(cLogitModel.klass, "w", VALUEFUNC(_wrap_LogitModel_w_get), -1);
8399
+ cLogitModel.mark = 0;
8400
+ cLogitModel.destroy = (void (*)(void *)) free_logitmodel;
8401
+ cLogitModel.trackObjects = 0;
8402
+
8403
+ cLogitMcState.klass = rb_define_class_under(mAlglib_ext, "LogitMcState", rb_cObject);
8404
+ SWIG_TypeClientData(SWIGTYPE_p_logitmcstate, (void *) &cLogitMcState);
8405
+ rb_define_alloc_func(cLogitMcState.klass, _wrap_LogitMcState_allocate);
8406
+ rb_define_method(cLogitMcState.klass, "initialize", VALUEFUNC(_wrap_new_LogitMcState), -1);
8407
+ rb_define_method(cLogitMcState.klass, "brackt=", VALUEFUNC(_wrap_LogitMcState_brackt_set), -1);
8408
+ rb_define_method(cLogitMcState.klass, "brackt", VALUEFUNC(_wrap_LogitMcState_brackt_get), -1);
8409
+ rb_define_method(cLogitMcState.klass, "stage1=", VALUEFUNC(_wrap_LogitMcState_stage1_set), -1);
8410
+ rb_define_method(cLogitMcState.klass, "stage1", VALUEFUNC(_wrap_LogitMcState_stage1_get), -1);
8411
+ rb_define_method(cLogitMcState.klass, "infoc=", VALUEFUNC(_wrap_LogitMcState_infoc_set), -1);
8412
+ rb_define_method(cLogitMcState.klass, "infoc", VALUEFUNC(_wrap_LogitMcState_infoc_get), -1);
8413
+ rb_define_method(cLogitMcState.klass, "dg=", VALUEFUNC(_wrap_LogitMcState_dg_set), -1);
8414
+ rb_define_method(cLogitMcState.klass, "dg", VALUEFUNC(_wrap_LogitMcState_dg_get), -1);
8415
+ rb_define_method(cLogitMcState.klass, "dgm=", VALUEFUNC(_wrap_LogitMcState_dgm_set), -1);
8416
+ rb_define_method(cLogitMcState.klass, "dgm", VALUEFUNC(_wrap_LogitMcState_dgm_get), -1);
8417
+ rb_define_method(cLogitMcState.klass, "dginit=", VALUEFUNC(_wrap_LogitMcState_dginit_set), -1);
8418
+ rb_define_method(cLogitMcState.klass, "dginit", VALUEFUNC(_wrap_LogitMcState_dginit_get), -1);
8419
+ rb_define_method(cLogitMcState.klass, "dgtest=", VALUEFUNC(_wrap_LogitMcState_dgtest_set), -1);
8420
+ rb_define_method(cLogitMcState.klass, "dgtest", VALUEFUNC(_wrap_LogitMcState_dgtest_get), -1);
8421
+ rb_define_method(cLogitMcState.klass, "dgx=", VALUEFUNC(_wrap_LogitMcState_dgx_set), -1);
8422
+ rb_define_method(cLogitMcState.klass, "dgx", VALUEFUNC(_wrap_LogitMcState_dgx_get), -1);
8423
+ rb_define_method(cLogitMcState.klass, "dgxm=", VALUEFUNC(_wrap_LogitMcState_dgxm_set), -1);
8424
+ rb_define_method(cLogitMcState.klass, "dgxm", VALUEFUNC(_wrap_LogitMcState_dgxm_get), -1);
8425
+ rb_define_method(cLogitMcState.klass, "dgy=", VALUEFUNC(_wrap_LogitMcState_dgy_set), -1);
8426
+ rb_define_method(cLogitMcState.klass, "dgy", VALUEFUNC(_wrap_LogitMcState_dgy_get), -1);
8427
+ rb_define_method(cLogitMcState.klass, "dgym=", VALUEFUNC(_wrap_LogitMcState_dgym_set), -1);
8428
+ rb_define_method(cLogitMcState.klass, "dgym", VALUEFUNC(_wrap_LogitMcState_dgym_get), -1);
8429
+ rb_define_method(cLogitMcState.klass, "finit=", VALUEFUNC(_wrap_LogitMcState_finit_set), -1);
8430
+ rb_define_method(cLogitMcState.klass, "finit", VALUEFUNC(_wrap_LogitMcState_finit_get), -1);
8431
+ rb_define_method(cLogitMcState.klass, "ftest1=", VALUEFUNC(_wrap_LogitMcState_ftest1_set), -1);
8432
+ rb_define_method(cLogitMcState.klass, "ftest1", VALUEFUNC(_wrap_LogitMcState_ftest1_get), -1);
8433
+ rb_define_method(cLogitMcState.klass, "fm=", VALUEFUNC(_wrap_LogitMcState_fm_set), -1);
8434
+ rb_define_method(cLogitMcState.klass, "fm", VALUEFUNC(_wrap_LogitMcState_fm_get), -1);
8435
+ rb_define_method(cLogitMcState.klass, "fx=", VALUEFUNC(_wrap_LogitMcState_fx_set), -1);
8436
+ rb_define_method(cLogitMcState.klass, "fx", VALUEFUNC(_wrap_LogitMcState_fx_get), -1);
8437
+ rb_define_method(cLogitMcState.klass, "fxm=", VALUEFUNC(_wrap_LogitMcState_fxm_set), -1);
8438
+ rb_define_method(cLogitMcState.klass, "fxm", VALUEFUNC(_wrap_LogitMcState_fxm_get), -1);
8439
+ rb_define_method(cLogitMcState.klass, "fy=", VALUEFUNC(_wrap_LogitMcState_fy_set), -1);
8440
+ rb_define_method(cLogitMcState.klass, "fy", VALUEFUNC(_wrap_LogitMcState_fy_get), -1);
8441
+ rb_define_method(cLogitMcState.klass, "fym=", VALUEFUNC(_wrap_LogitMcState_fym_set), -1);
8442
+ rb_define_method(cLogitMcState.klass, "fym", VALUEFUNC(_wrap_LogitMcState_fym_get), -1);
8443
+ rb_define_method(cLogitMcState.klass, "stx=", VALUEFUNC(_wrap_LogitMcState_stx_set), -1);
8444
+ rb_define_method(cLogitMcState.klass, "stx", VALUEFUNC(_wrap_LogitMcState_stx_get), -1);
8445
+ rb_define_method(cLogitMcState.klass, "sty=", VALUEFUNC(_wrap_LogitMcState_sty_set), -1);
8446
+ rb_define_method(cLogitMcState.klass, "sty", VALUEFUNC(_wrap_LogitMcState_sty_get), -1);
8447
+ rb_define_method(cLogitMcState.klass, "stmin=", VALUEFUNC(_wrap_LogitMcState_stmin_set), -1);
8448
+ rb_define_method(cLogitMcState.klass, "stmin", VALUEFUNC(_wrap_LogitMcState_stmin_get), -1);
8449
+ rb_define_method(cLogitMcState.klass, "stmax=", VALUEFUNC(_wrap_LogitMcState_stmax_set), -1);
8450
+ rb_define_method(cLogitMcState.klass, "stmax", VALUEFUNC(_wrap_LogitMcState_stmax_get), -1);
8451
+ rb_define_method(cLogitMcState.klass, "width=", VALUEFUNC(_wrap_LogitMcState_width_set), -1);
8452
+ rb_define_method(cLogitMcState.klass, "width", VALUEFUNC(_wrap_LogitMcState_width_get), -1);
8453
+ rb_define_method(cLogitMcState.klass, "width1=", VALUEFUNC(_wrap_LogitMcState_width1_set), -1);
8454
+ rb_define_method(cLogitMcState.klass, "width1", VALUEFUNC(_wrap_LogitMcState_width1_get), -1);
8455
+ rb_define_method(cLogitMcState.klass, "xtrapf=", VALUEFUNC(_wrap_LogitMcState_xtrapf_set), -1);
8456
+ rb_define_method(cLogitMcState.klass, "xtrapf", VALUEFUNC(_wrap_LogitMcState_xtrapf_get), -1);
8457
+ cLogitMcState.mark = 0;
8458
+ cLogitMcState.destroy = (void (*)(void *)) free_logitmcstate;
8459
+ cLogitMcState.trackObjects = 0;
8460
+
8461
+ cMNLReport.klass = rb_define_class_under(mAlglib_ext, "MNLReport", rb_cObject);
8462
+ SWIG_TypeClientData(SWIGTYPE_p_mnlreport, (void *) &cMNLReport);
8463
+ rb_define_alloc_func(cMNLReport.klass, _wrap_MNLReport_allocate);
8464
+ rb_define_method(cMNLReport.klass, "initialize", VALUEFUNC(_wrap_new_MNLReport), -1);
8465
+ rb_define_method(cMNLReport.klass, "ngrad=", VALUEFUNC(_wrap_MNLReport_ngrad_set), -1);
8466
+ rb_define_method(cMNLReport.klass, "ngrad", VALUEFUNC(_wrap_MNLReport_ngrad_get), -1);
8467
+ rb_define_method(cMNLReport.klass, "nhess=", VALUEFUNC(_wrap_MNLReport_nhess_set), -1);
8468
+ rb_define_method(cMNLReport.klass, "nhess", VALUEFUNC(_wrap_MNLReport_nhess_get), -1);
8469
+ cMNLReport.mark = 0;
8470
+ cMNLReport.destroy = (void (*)(void *)) free_mnlreport;
8471
+ cMNLReport.trackObjects = 0;
8472
+ rb_define_module_function(mAlglib_ext, "mnltrainh", VALUEFUNC(_wrap_mnltrainh), -1);
8473
+ rb_define_module_function(mAlglib_ext, "mnlprocess", VALUEFUNC(_wrap_mnlprocess), -1);
8474
+ rb_define_module_function(mAlglib_ext, "mnlunpack", VALUEFUNC(_wrap_mnlunpack), -1);
8475
+ rb_define_module_function(mAlglib_ext, "mnlpack", VALUEFUNC(_wrap_mnlpack), -1);
8476
+ rb_define_module_function(mAlglib_ext, "mnlserialize", VALUEFUNC(_wrap_mnlserialize), -1);
8477
+ rb_define_module_function(mAlglib_ext, "mnlcopy", VALUEFUNC(_wrap_mnlcopy), -1);
8478
+ rb_define_module_function(mAlglib_ext, "mnlunserialize", VALUEFUNC(_wrap_mnlunserialize), -1);
8479
+ rb_define_module_function(mAlglib_ext, "mnlavgce", VALUEFUNC(_wrap_mnlavgce), -1);
6125
8480
  }
6126
8481