Réponse apportée
nlinfit - iteration limit exceeded error
Probably your termination tolerance is too small for the data you're throwing at it. Play with the options 'MaxIter', 'TolFun...

presque 14 ans il y a | 0

Réponse apportée
detect the longest edge and calculate the slope
What about using the Hough transform to detect lines in your edge image? You could search the resulting Hough-space for lines w...

presque 14 ans il y a | 0

Réponse apportée
How to write a loop for adding number
If you think about what you're doing, it's just a cumulative sum. Put all your variables into a vector: vec = [a b c d ....

presque 14 ans il y a | 0

Réponse apportée
adding data to a text file
I remember answering an almost identical question from you the other day. It used the fopen() with the open-mode 'w' to overwri...

presque 14 ans il y a | 1

Réponse apportée
loop-free numeric array indexing when numeric array inside cell array
You can use *cellfun* for this if you combine the _C_ and _ind_ cell arrays: _ie_ chuck the _ind_ array as a new column in _C_....

presque 14 ans il y a | 0

| A accepté

Réponse apportée
trouble for importing a data file
Using *textread* is fine here. But you need to include as many fields in your format string as you expect to see in the file,...

presque 14 ans il y a | 0

Réponse apportée
Multithreading with mex functions
I'm not sure if I've interpreted your question correctly, but I think your main problem is working out how to get data back to M...

presque 14 ans il y a | 2

| A accepté

Réponse apportée
Best way to structure code with large matrices shared between multiple functions
MatLab is pretty clever about when to copy and when to pass by reference. Generally, a matrix passed as a parameter will only b...

presque 14 ans il y a | 0

Réponse apportée
browse for an excel file and save the data as a matrix
Use the function *uigetfile* to browse for a filename, then pass that name to *xlsread*.

presque 14 ans il y a | 0

| A accepté

Réponse apportée
importdata() question
Are you sure? If you look closely, you'll see the display is saying '1.0e+003 *'. That means your numbers are correct, but are...

presque 14 ans il y a | 0

Réponse apportée
Extract part of the text file
I would do it as follows: First, slurp the entire file into a cell array. fileID = fopen('input.txt', 'r'); lines =...

presque 14 ans il y a | 0

| A accepté

Réponse apportée
overwrite a text file with other data
Let's say your value is in the variable called v: v = [3 6 9]; You can use _save_ which will output lots of extra decima...

presque 14 ans il y a | 0

Réponse apportée
error in reading frames
You're constructing one filename out of lots of them. You're also assuming that the files are listed in order. You need to get...

presque 14 ans il y a | 0

| A accepté

Réponse apportée
Kinect(Microsoft SDK) Skeleton (recorded ) Data from pixel to 3d World Coordinates
Are you saying you acquired the same gesture data from the same unit but in different formats? Are your time stamps the same? ...

presque 14 ans il y a | 0

Réponse apportée
Connecting matlab and visual studio
If this is to be deployed on a server somewhere, it might get a little fiddly. However, if you simply have MatLab and VS runn...

presque 14 ans il y a | 1

| A accepté

Réponse apportée
lsqcurve fit precision problem?
Probably, like you say, related to scale. You can use _optimset_ to adjust the solver: > opts = optimset('lsqcurvefit');...

presque 14 ans il y a | 0

Réponse apportée
random number from a data set with a specified error
This question is open to interpretation. What I _think_ you have is a dataset X with known standard deviations S (a vector co...

presque 14 ans il y a | 0

| A accepté

Réponse apportée
Plane in 3D space
Without really trying to look at your maths, let me suggest that you will have less issues if you treat your 3D objects in a sta...

presque 14 ans il y a | 0

| A accepté

Réponse apportée
Function to format number as currency?
Hehe, everyone's got a different function. I wrote a pretty inefficient tail-recursive solution, which might not be the "MatLab...

presque 14 ans il y a | 0

Réponse apportée
Correlation values of various time periods
It appears you just want an index that slices the data in intervals: N = length(Data.L1); idx1hr = 1:N; idx2hr = 1:...

presque 14 ans il y a | 0

Réponse apportée
find a string element in a structure matrix
Direct comparison operators (==, etc) don't work with strings. You need to use _strcmp_ or _strcmpi_ (which ignores case). ...

presque 14 ans il y a | 1

Réponse apportée
How can I format a percent using 2 digits after the decimal
If you want to do it without using strings: round(x * 100) / 100; One reason you might want to do that is if you have a ...

presque 14 ans il y a | 3

Réponse apportée
Constrained Polynomial Regression
So you mean that you want to constrain a cubic polynomial regression such that the x^2 term is zero? For this I would use _fs...

presque 14 ans il y a | 2

| A accepté

Réponse apportée
Extracting a block from a big array
I like using _find_ for these kinds of problems. To find all the starting indices of your blocks, you can go: idxStart = f...

presque 14 ans il y a | 0

Réponse apportée
Variable name not coming properly in the generated code
Does it happen when you have other numeric suffices on your variable names? _ie_ if you have the variable 'abc_f31' or 'abc_f33...

presque 14 ans il y a | 0

Réponse apportée
converting decimal year into julian day or a [Y,M,D] vector??
That's not the correct usage of datevec and datestr. The first thing you need to do is work out how many days are in that yea...

presque 14 ans il y a | 3

| A accepté

Réponse apportée
Move subplot title and create colored line beside it.
I don't know how to answer your 'line' question, but to set the title position do this: h = get(gca, 'Title'); set(h, 'U...

presque 14 ans il y a | 1

Réponse apportée
saving a value and reseting other variables in a loop
I think you're asking two questions: a) Why is the indexing broken? b) What is a better way to do this? I'll ask you my...

presque 14 ans il y a | 0

| A accepté

Réponse apportée
please i need to know How connect sql with matlab???
WampServer uses MySQL, I believe. You need to install the MySQL ODBC driver: <http://dev.mysql.com/downloads/connector/odbc/...

environ 14 ans il y a | 2

| A accepté

Réponse apportée
Making change with coins, problem (greedy algorithm)
Have already voted on Srinivas' correct answer to your question, but this is for your interest and study: function [coins] ...

environ 14 ans il y a | 2

Charger plus