package weka.classifiers.myalgorithm;
import com.mathworks.toolbox.javabuilder.MWException;
import timeseries.regress_time_series;
public class TestTimeSeries {
/**
* @param args
*/
public static void main(String[] args) throws MWException {
regress_time_series rs = new regress_time_series();
try {
double[][] getD = new double[][] { { 1, 3.878945921 },
{ 2, 3.522376476 }, { 3, 3.569071412 }, { 4, 3.522676476 },
{ 5, 3.559571412 }, { 6, 3.522376476 }, { 7, 3.559074412 },
{ 8, 3.524376476 }, { 9, 3.559071422 },
{ 28, 3.542576476 }, { 29, 3.559543412 } };
String figPath = "E:\\image";// /图像保存路径,特别注意,这个路径要用
float moveItemNum = 1;// 移动项数
float preDNum = 1; // 预测的个数
double[][] figSet = new double[][] { { 7 }, { 650 }, { 320 } };
String figName = "regress_time_series_figure.png";
// String figure_name="";
System.out.println(rs.regress_time_series(3, getD, moveItemNum,
preDNum, figPath, figName, figSet)[0]);
} catch (Exception ex) {
ex.printStackTrace();
}
}![](http://imgsrc.baidu.com/forum/w%3D580/sign=e37864112e34349b74066e8df9eb1521/eb429b2397dda1446b61e9b9b4b7d0a20df486e3.jpg)
MATLAB的m文件生成的包都导入正确,在包下com/mathworks/toolbox/javabuilder/internal/ComponentDataPtr 的.class没有,,求大神解答!
import com.mathworks.toolbox.javabuilder.MWException;
import timeseries.regress_time_series;
public class TestTimeSeries {
/**
* @param args
*/
public static void main(String[] args) throws MWException {
regress_time_series rs = new regress_time_series();
try {
double[][] getD = new double[][] { { 1, 3.878945921 },
{ 2, 3.522376476 }, { 3, 3.569071412 }, { 4, 3.522676476 },
{ 5, 3.559571412 }, { 6, 3.522376476 }, { 7, 3.559074412 },
{ 8, 3.524376476 }, { 9, 3.559071422 },
{ 28, 3.542576476 }, { 29, 3.559543412 } };
String figPath = "E:\\image";// /图像保存路径,特别注意,这个路径要用
float moveItemNum = 1;// 移动项数
float preDNum = 1; // 预测的个数
double[][] figSet = new double[][] { { 7 }, { 650 }, { 320 } };
String figName = "regress_time_series_figure.png";
// String figure_name="";
System.out.println(rs.regress_time_series(3, getD, moveItemNum,
preDNum, figPath, figName, figSet)[0]);
} catch (Exception ex) {
ex.printStackTrace();
}
}
![](http://imgsrc.baidu.com/forum/w%3D580/sign=e37864112e34349b74066e8df9eb1521/eb429b2397dda1446b61e9b9b4b7d0a20df486e3.jpg)
MATLAB的m文件生成的包都导入正确,在包下com/mathworks/toolbox/javabuilder/internal/ComponentDataPtr 的.class没有,,求大神解答!