Respondida
Optimization Simple search
Can you explain what you want beyond |min(x)|?

más de 15 años hace | 1

Respondida
common colorbar
Hard to say without seeing the code, but it looks like there's some condition that makes it possible for |layoutColorbar| to com...

más de 15 años hace | 0

| aceptada

Respondida
How to save statitiscs displayed in workspace as text file?
Do you mean you want a list of variable names, sizes, classes, bytes used,...? If so, you could do |vars = whos|, then save/wri...

más de 15 años hace | 0

| aceptada

Respondida
errors in this code - 1D PDE with Boundary Condition
I don't know exactly what you're trying to do with |t| and |T| (and associated |nt| and |NT|), but the result is that |c| and |C...

más de 15 años hace | 0

Respondida
loop for scatter plot
Like this? plot([A,A,A],[B,C,D],'o') *EDIT* Based on your comment, here's a new answer: allX = [A,A,A]; allY = [B,C,D];...

más de 15 años hace | 0

| aceptada

Respondida
Multi-variable minimization
What do you mean by "the minimum variables"? |x| is a vector, so what are you trying to minimize? All the x values? The norm ...

más de 15 años hace | 0

Respondida
Newton Raphson method
# Please format your code to make it more readable # Why do you want to display the iterations? But either way, just add a |di...

más de 15 años hace | 0

Respondida
Problem with my Code?
That message generally means that your function file isn't on the MATLAB path. Is Newton.m in your current directory? There ...

más de 15 años hace | 0

Respondida
Matrix visualisation with coloured box and numbers
|imagesc| and |text|. If it's like sudoku in that the range of values is fixed, use |image| and a custom |colormap|. *EDIT TO ...

más de 15 años hace | 1

Respondida
column into row
xcol = xx(:); Although, if you want to go by rows, transpose |xx| first.

más de 15 años hace | 0

Respondida
Graphical input from the grid - similar to game of life
|image| or |imagesc| with a custom three-color |colormap| to make the image, then |ginput| to get the point (and |round| as nece...

más de 15 años hace | 0

Respondida
how to load and calculate data from a file?
If |x| is a vector of 21 values (and all the other values are scalars), then all you need to do is idk=Is*(exp(x/(m*VT))-1)...

más de 15 años hace | 0

| aceptada

Respondida
How to get a an XY plotted curve to match another curve based on observed values?
Sounds like a regression/curve fitting problem? The right function to use depends a bit on the form of the model. If it's just...

más de 15 años hace | 0

Respondida
Validation of a date with a given format
fmt = 'dd mmm yyyy HH:MM:SS.FFF'; dt = []; while isempty(dt) x = input(['enter date string in ',fmt,' format: '],...

más de 15 años hace | 2

Respondida
matlab data parsing help- pulling only certain characters
You could use |regexprep|, but you could also modify your |textscan| format specifier to "notice" but not read these in the firs...

más de 15 años hace | 0

Respondida
Matrix help
If it's just a matter of how it's displayed: fprintf([repmat('%4s ',1,16),'\n'],C{:}) (Note, you normally need to trans...

más de 15 años hace | 0

| aceptada

Respondida
Sum and average even numbers
Why bother? The answer is |-Inf|. Your teacher needs to write more precise questions.

más de 15 años hace | 3

Respondida
nice boxes for great linewidths
From my experiments, it appears to be a combination of what Matt Fig said, and just the translation to png. This worked OK for ...

más de 15 años hace | 1

Respondida
dlm read error in data import - alternatives?
Give this a try function windcan fprintf ('See http://climate.weatheroffice.ec.gc.ca/climateData/canada_e.html \n se...

más de 15 años hace | 0

| aceptada

Respondida
3D Plotting with Vectors and Meshgrid
There are times when, much as I love to mess with matrices and/or |bsxfun|, a |for|-loop is just the easiest way to go: Z = z...

más de 15 años hace | 1

| aceptada

Respondida
dataset
x = dataset('file','simple.txt','delimiter',' ') x.Properties.VarNames x.a plot(x.a,x.b,'o-')

más de 15 años hace | 1

Respondida
fitting lognaormal distribution with constraints
The lognormal distribution has two parameters (mu & sigma). If you impose two constraints (namely that the fitted distribution ...

más de 15 años hace | 1

| aceptada

Respondida
Write a program that calculates sum of the integers numbers
disp(240) Or, for pedants who claim that evaluation is not the same as calculation, disp(239+1)

más de 15 años hace | 1

Respondida
ODE45
You do not have to write a function file, but you do have to define a function. You've defined |y1| to |y4| as numeric variable...

más de 15 años hace | 0

Respondida
Numerical solution of integral equation with parametric variable
A variation on Jarrod's approach, using function handles (because everyone loves function handles): myFunc = @(t,b) exp(t*b...

más de 15 años hace | 1

Respondida
system of odes
The problem is your argument list for |fxx|. ODE functions should be functions of the independent variable, then the dependent ...

más de 15 años hace | 1

| aceptada

Respondida
Contributors metainfo: reputation and more
For once I get to scoop Walter: *Congratulations to Walter R for successfully avoiding any Y2K issues in rolling over to the ...

más de 15 años hace | 0

Respondida
Plot different classes in different colors
<http://www.mathworks.com/help/toolbox/stats/gscatter.html |gscatter|> doesn't do what you're looking for?

más de 15 años hace | 1

Respondida
Doubt math
OK, to expand on the cyclist's answer: # rewrite your equation in the form f(I) = 0: ICC - IR.*(exp((V1+Rs*I)./(m.*VT))-1) - ...

más de 15 años hace | 0

| aceptada

Respondida
Problem only reading in select data
On the off-chance Walter's approach doesn't work (eg there are more than two block formats in the file), here's a more brute-for...

más de 15 años hace | 1

| aceptada

Cargar más