답변 있음
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...

13년 초과 전 | 1

| 수락됨

답변 있음
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 =...

13년 초과 전 | 20

| 수락됨

답변 있음
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-...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

답변 있음
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 ...

13년 초과 전 | 1

| 수락됨

답변 있음
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...

13년 초과 전 | 1

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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 ...

13년 초과 전 | 1

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 1

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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. ...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

답변 있음
Understanding output of perfcurve
Could it be that you have relatively few distinct values of classpredict?

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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 ...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 1

| 수락됨

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 2

답변 있음
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...

13년 초과 전 | 0

답변 있음
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...

13년 초과 전 | 0

| 수락됨

답변 있음
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...

13년 초과 전 | 0

답변 있음
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:...

13년 초과 전 | 1

| 수락됨

더 보기