Question

I have downloaded the binary Zip from here. I extracted the zip to a folder. Then I right clicked on libs folder in Eclipse. I Imported the *.jar file to the libs folder, and then I right clicked on it and added to path. I added

 import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics;

to my java file, and i am adding values to

DescriptiveStatistics rStandardDeviation = new DescriptiveStatistics();

and after that I run the math part by:

double bMean = bStandardDeviation.getMean();
double rStd = rStandardDeviation.getStandardDeviation();

No errors on compile, clean, or build. When I attempt to run the app on my phone i get:

Could not find class 'org.apache.commons.math3.stat.descriptive.DescriptiveStatistics', referenced from method com.example.mydemo.MainActivity.<init>

Any ideas anyone what is going wrong?

Thank you

Was it helpful?

Solution

In your Build Configuration, make sure you check your library to be exported in Order and Export. See

enter image description here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top