Respondida
How to apply a cell array of function handles to a cell array of arguments
Use nested cellfun calls X = cellfun(@(fha_i) cellfun(fha_i, C, 'Uni', false), fha, 'Uni', false)

más de 9 años hace | 0

Respondida
Negative index of a matrix
for n = 1:5 m = -n:n; for i = 1:numel(m) A(i, n) = m(i)*n; end end

más de 9 años hace | 0

| aceptada

Respondida
How to use data from columns whose header lines meet two criteria?
D = [125 250 500 125 250 1 1 1 3 3 91.34 119.5 127.88 113.96 114.09 91.35 120.28 126.28 109.82 117.63 91.36 116.25 123...

más de 9 años hace | 0

| aceptada

Respondida
select row and iterate for next rows
If you want to multiply column 1 by alpha = 23 and add column 2, for example, you can to this as follows: alpha = 23; y ...

más de 9 años hace | 0

Respondida
fprintf doesn't create new lines
You can fprint to fid == 1 to view the result on the console for testing. This creates newlines fprintf(1,'%d\n', [1 2 3])

más de 9 años hace | 1

| aceptada

Respondida
Measuring fit of normcdf and multiple data points
Compute the error from the distance of the points to the line err = p_collapse_mle(x_vals == IM) - num_collapse./num_gms; ...

más de 9 años hace | 1

| aceptada

Respondida
Figure & Subplot: Getting rid of needless white space
Try FEX submission tight_subplot

más de 9 años hace | 1

Respondida
how to represent e raised to power of x expressions
exp(1j*2*pi*f*T)

más de 9 años hace | 0

| aceptada

Respondida
How to retrieve data in column wise in Matlab?
A(:, [1 4])

más de 9 años hace | 0

| aceptada

Respondida
32 and 64 bit on same computer
If you have a 64 bit machine you can only install the 64 bit version of Matlab.

más de 9 años hace | 0

Respondida
How to calculate concordant pairs in MATLAB
nnz(sign(A(2:end) - A(1:end-1)) == sign(B(2:end) - B(1:end-1)))

más de 9 años hace | 0

Respondida
How can I subtract vectors of different lengths?
You do not need much code, you can simply write delta = LargerVec(1:numel(SmallerVec))-SmallerVec; or if you want to del...

más de 9 años hace | 0

| aceptada

Respondida
Using Mac book Air 2015
Yes, why not? If the CPU and RAM is sufficient for what you consider smooth working depends on the task you want to do, of which...

más de 9 años hace | 0

Respondida
need a help doing simple code
To learn Matlab you can start by something like function y = myfunction(W, L, H, R) q=H/L; a=W/q; b=(W*(1-R)/(2*q)); ...

más de 9 años hace | 0

| aceptada

Respondida
How to calculate gradient of arbitrary point based on image
One way would be to calculate the gradient for each pixel and then interpolate to get sub pixel accuracy.

más de 9 años hace | 0

Respondida
Speed up indexing / Repmat operation
nnz(I) may be faster than sum for logical matrices. Another way could be to pre-allocate cells of ones for all possible ...

más de 9 años hace | 0

Respondida
How to convert a ASCII character to matrix
There are datasets around; google 8 x 8 character bitmaps One example is <https://github.com/dhepper/font8x8> To extract a...

más de 9 años hace | 0

Respondida
Help using textscan on .csv files
To check if your string contains any invalid characters, i.e., non-digits, you can use ~isempty(regexp(s, '\D')) and the...

más de 9 años hace | 0

Respondida
How to make margins in figure again?
help iptsetpref reveals iptsetpref('ImshowBorder','loose')

más de 9 años hace | 0

Respondida
What is the reason to get 'The system cannot find the path specified.'?
Have a look at the run_demos_videos file and see if there are any paths set that do not exist on your system.

más de 9 años hace | 1

Respondida
How to get image from a matrix which contains PIXEL values ?
I used Input_Im = imread('peppers.png'); and it worked fine. What do you get with peppers.png?

más de 9 años hace | 0

Respondida
Create sparse matrices with integer rows and columns
Probably not. See also <http://stackoverflow.com/questions/30894231/matlab-uint8-sparse>

más de 9 años hace | 0

| aceptada

Respondida
Getting pixel values from an image
If your image is stored in I, like from the command I = imread('peppers.png'); the Matlab syntax to select the element in...

más de 9 años hace | 2

| aceptada

Respondida
What does this commands mean?
It generates the numbers from 1 up to C, in steps of 6.

más de 9 años hace | 1

| aceptada

Respondida
How to make input parameters in m.file and use another function file to write the code, and ask paramters from m.file?
write a script parameters.m alpha = 23; beta = 44; write a function function z = myfunction(x, y) % read scr...

más de 9 años hace | 2

Respondida
randomly select different elements of a vector
x = [1 1 1 2 3 4 4 4 5 6 7 7]; for i = 1:4 ind = randperm(numel(x), 1); % select one element out of numel(x) element...

más de 9 años hace | 1

| aceptada

Respondida
How do i write the following mathematical equation in MATLAB
If SM is a M * N matrix, you can write mean2(SM) or if you don't have the image processing toolbox mean2(SM(:))

más de 9 años hace | 0

Respondida
Decrease the least and increase the highest
B(A == max(A)) = B(A == max(A))*100; B(A == min(A)) = B(A == min(A))*10;

más de 9 años hace | 0

Cargar más