Beantwortet
Neighbor and center points of matrix
See my 25-Feb-2008 blog post called "Neighbor indexing" for a general technique. You'll need to pay careful attention to what h...

etwa 4 Jahre vor | 1

Beantwortet
Fourier Transform of a signal
The fft function in MATLAB computes something called the discrete Fourier transform. Your problem here is asking you to find som...

etwa 4 Jahre vor | 0

Beantwortet
How can I create a 3D array?
Try something like this: for i = 1:n-1 next_image = uigetfile('*p*'); ImageArray = cat(3,ImageArray,next_image); end...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
customize export setup to generate SVG
Try this: h = findall(fig,'-property','FontName'); set(h,'FontName','San Serif'); print(fig,'-dsvg','mygraphic.svg')

etwa 4 Jahre vor | 1

Beantwortet
load rwb gives error
You're looking for a file called rwb.mat. Once you find it, put it in your current working folder or in a folder that's on the M...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
How to get the x and y coordinates of the each marker in a frame?
I used the Color Thresholder app to get code that segments your image based on the green color of the markers. Then I used regio...

etwa 4 Jahre vor | 0

Beantwortet
Give an unknown number of parameters to feval
Put your parameters in a cell array and then use the syntax that expands a cell array into a comma-separated list: out = feval(...

etwa 4 Jahre vor | 0

| akzeptiert

Beantwortet
Infinite Recursion in own Levenberg-Marquardt Code
I see that korrektur is calling itself recursively. I noticed also that the recursive call appears to be identical to the top-le...

etwa 4 Jahre vor | 1

Beantwortet
Text increments of the x-axis
Sure, you can set the XTicks property of the axes object directly. ax = gca; ax.XTicks = [1 2 3]; A shortcut for this is: xt...

etwa 4 Jahre vor | 0

Beantwortet
imshow doesn't display png image file
Your image is stored in the PNG file as unsigned 16-bit integers. When imshow displays a uint16 image, it uses the unsigned 16-b...

etwa 4 Jahre vor | 1

| akzeptiert

Beantwortet
How to plot particle trajectories and normalise to 0,0 origin?
Here is one way you could do it. Read in the whole Excel file as a table. Then, in a loop, extract the particle data for each tr...

etwa 4 Jahre vor | 1

Beantwortet
From for to While loop
Here is one way to convert a typical MATLAB for loop to a while loop: for i = 1:N ... end i = 1; while i <= N .....

etwa 4 Jahre vor | 0

Beantwortet
Select data from CSV file based on character in position, then read that character and next 2 character, of different read that character and next 3
MATLAB has a number of functions that can automatically read and parse CSV files and return the results in a useful form. Try re...

etwa 4 Jahre vor | 0

Beantwortet
Vectorize "for"-loop in multidimentional array
It is conceivable that the loop might be eliminated with some sub2ind calculations followed by linear indexing, but I would expe...

mehr als 4 Jahre vor | 0

Beantwortet
Sort a table in ascending order
The answer would be relatively straightforward, as well as much more efficient, if you would orient your table the other way. Wi...

mehr als 4 Jahre vor | 1

| akzeptiert

Beantwortet
How to transform a RGB matrix to a weighted adjacency matrix?
Borys, I tackled your problem and wrote a blog post about it: "Transforming a color image to a weighted adjacency matrix"

mehr als 4 Jahre vor | 1

| akzeptiert

Beantwortet
Two colormaps in the same plot
The ColorBar object has an undocumented Colormap property. You can set this property directly to control the colors displayed by...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Two colormaps in the same plot
You can't display images with two different colormaps within the same axes. As a workaround, you could convert both images from ...

mehr als 4 Jahre vor | 0

Beantwortet
How to get rid of deconvolution artifacts?
I think this is because you are performing inverse filtering in the frequency domain, and the blurring function has zeros (or al...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Function inside for loop not working
One possible explanation for the observed behavior is that the variable hcube does not actually contain a hypercube object when ...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Extract transformation matrix from image distortion
In your call to fitgeotrans, you have specified that you want a 'polynomial' transformation. This type of transformation is not ...

mehr als 4 Jahre vor | 1

| akzeptiert

Beantwortet
Trying add chunk of data to a array
As I understand the code, the fact that ls is empty after the loop implies that either: The while loop body never executes The...

mehr als 4 Jahre vor | 1

Beantwortet
Averaging each .STD files
Try this: files = dir("*.Std"); N = numel(files); Date = NaT(0,1); X = zeros(0,3); for k = 1:numel(files) name = str...

mehr als 4 Jahre vor | 0

Beantwortet
Averaging each .STD files
[Update: Based on comments from Moses, I submitted another answer to this question. See below.] Try this: files = dir("*.Std")...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Get edge points from a hough line
I think I understand your question. Here is one possibility. Using the function intline from the DIPUM Toolbox, create a binary...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Variable Variation over the same range
I am interpreting your question this way: you would like to compute depth_tot_7 for all possible combinations of the different v...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
Combine griddedInterpolants on the same grid
I don't think so. If you have a large number of query points, you might try replacing the Values property of the griddedInterpol...

mehr als 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to plot multiple graphs using the 3 variable array values
Here is one way: h = 0:0.008:0.600; rho = 1000; g = 9.81; F = rho*g*L*(0.5*(h).^2); F1 = F/1000; E = 2.1E11; I = ((0.008)...

mehr als 4 Jahre vor | 1

| akzeptiert

Beantwortet
Switch-case function problem
First variation: fix the switch and case lines and the indexing into cName. switch color(ind) case 0 ...

mehr als 4 Jahre vor | 1

| akzeptiert

Beantwortet
Reversing/Alternatives of function handles
One of the major uses of function handles is for use with functions that operate on other functions. For example, you can use th...

mehr als 4 Jahre vor | 1

Mehr laden