Beantwortet
How to plot a probability density function on a histogram?
Your code appears to use a variable "score" without defining it. You can create the histogram by calculating it yourself as y...

mehr als 13 Jahre vor | 1

| akzeptiert

Beantwortet
plotting multiple boxplots in the same figure window
Here's how to do that with three vectors of different lengths: x1 = rand(10,1); x2 = 2*rand(15,1); x3 = randn(30,1); x =...

mehr als 13 Jahre vor | 20

| akzeptiert

Beantwortet
using logistic regression on matlab for given x and y
Here's a way to fit a logistic curve to continuous data using Curve Fitting: >> x = rand(100,1); >> y = 1./(1+exp(-3*(x-...

mehr als 13 Jahre vor | 0

Beantwortet
How do you choose values from a distribution according to their respective probabilities?
Consider the randsample function if you have the Statistics Toolbox, or look here: <http://www.mathworks.com/matlabcentral/an...

mehr als 13 Jahre vor | 0

Beantwortet
I got 3 square cluster from 12 (x,y) points. How can I find out which points it is taking for making the clusters?
I may not follow your request. The variable T indicates which row of X belongs to each cluster. If you want to show that on the ...

mehr als 13 Jahre vor | 1

| akzeptiert

Beantwortet
how to code to solve for coefficient using linear regression?
It is hard to know what method you should use without understanding the problem more. One method is this. Suppose x and y are co...

mehr als 13 Jahre vor | 1

Beantwortet
How do I obtain regression coefficients from a large data set?
Perhaps you can build on this. Here I set up some fake data with a known relationship with a single outcome variable. Then I loo...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
coefTest and one tailed T-test
You are right that the result from coefTest is an F-test. There is no built-in way to carry out a one-sided t test. Here are ...

mehr als 13 Jahre vor | 1

| akzeptiert

Beantwortet
How to derive a CDF from a given PDF?
If you have the Symbolic Toolbox, you might try replacing normcdf by an erf function and see what you get. Otherwise you coul...

mehr als 13 Jahre vor | 0

Beantwortet
Is there a way to restrict interactions to a subset GeneralizedLinearRegression.stepwise
Yes, it is possible to specify 'Upper' as a model that is the upper bound of all terms to consider. For example: y = 1 + x1...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
Problem using trapz for obtaining probabilities
I don't quite understand what you are trying to do. I suggest you consider d=0 and step through your code to see why the first n...

mehr als 13 Jahre vor | 0

Beantwortet
Matlab function for the calculation of G-efficiency and D-efficiency coefficients of D-optimal DoE ?
The D-optimal design maximizes the determinant of X'*X where X is the design matrix. If you have the Statistics Toolbox you coul...

mehr als 13 Jahre vor | 1

Beantwortet
check whether regression slopes are different between 3 groups
Your code looks right to me. If you have a recent version of the Statistics Toolbox, your job would be somewhat simpler if yo...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
There exists, logspace, linspace, what about probability space?
You haven't said what probability distribution you want. If it's the standard normal distribution, you could try norminv(.1...

mehr als 13 Jahre vor | 0

Beantwortet
K-means clustering ignoring zero values
In that demo clustering is performed on the variable ab, then the result are reshaped and put into the variable pixel_labels. ...

mehr als 13 Jahre vor | 0

Beantwortet
Weighted Least Squares, Need Help!!
Well, y.*w multiplies each element of y by the corresponding element of w. To do this with a matrix x having multiple columns, t...

mehr als 13 Jahre vor | 0

Beantwortet
Corrcoef and R^2 definition give different R^2 values
I would expect your formula to work if simulation is a set of predicted values from fitting ydata using least squares as a funct...

mehr als 13 Jahre vor | 0

Beantwortet
Understanding output of perfcurve
Could it be that you have relatively few distinct values of classpredict?

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
Why is bootci not terminating?
The default bootci 'type' is bca. This requires doing a jackknife and it can take a long time if the number of data rows is larg...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
sampling from a mixture of 2 multivariate Gaussian distributions
If you have the Statistics Toolbox, type "help gmdistribution". You can use it to construct a mixture of two Gaussians, then use...

mehr als 13 Jahre vor | 0

Beantwortet
unable to fit Gaussian mixture model
I don't know much about analyzing images. But gmdistribution expects its input data to be samples drawn from a Gaussian mixture ...

mehr als 13 Jahre vor | 0

Beantwortet
nnmf function usage problem
Most Statistics Toolbox functions aren't written to operate on integer data types. Try nnmf(double(resim),100) to convert to dou...

mehr als 13 Jahre vor | 1

| akzeptiert

Beantwortet
Boxplot (with several groups/days) + Plot (for each group/day)
Sorry, your frustration led me to try it myself. Here's what I did: a = rand(3,4); b = 10*rand(3,4); figure(1); bar(a...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
Boxplot (with several groups/days) + Plot (for each group/day)
Here's how you can set the color of the first group: h = bar(Y, 'group'); set(h(1),'FaceColor','r') If you are conten...

mehr als 13 Jahre vor | 0

Beantwortet
wald test or test of equality of means
In an older release, check out "help linhyptest". It can perform a hypothesis test on coefficients given estimates and a covaria...

mehr als 13 Jahre vor | 0

Beantwortet
integrating the product of two pdf's
Here's an example that you may be able to adapt to your problem. Suppose [x1;x2] have a multivariate normal distribution with...

mehr als 13 Jahre vor | 2

Beantwortet
integrating the product of two pdf's
What is the "space" variable intended to represent? Based on your integral expression, I'd expect the result to be a function...

mehr als 13 Jahre vor | 0

Beantwortet
Integration of multivariate normal cumulative distribution function
I assume you really want to integrate the cdf, rather than compute the cdf which is the integral of the pdf. The dblquad func...

mehr als 13 Jahre vor | 0

| akzeptiert

Beantwortet
wald test or test of equality of means
I assume you mean you want to test the equality of two regression coefficients. This will work in the current release of the Sta...

mehr als 13 Jahre vor | 0

Beantwortet
ovlay cdf plot on histogram
It's there but it's on the histogram scale and it is obscured by the bars. Try this instead to put the cdf on a separate y axis:...

mehr als 13 Jahre vor | 1

| akzeptiert

Mehr laden