Community Profile

Pekka Kumpulainen


531 total contributions since 2007

Contact

Contributions in
View by

Submitted


tight_subplot(Nh, Nw, gap, marg_h, marg_w)
Fills the figure with axes subplots with easily adjustable margins and gaps between the axes.

9 months ago | 311 downloads |

Thumbnail

Responded


Re: Drawing a Legend in a graph
Without knowing what exactly is the problem, here is an example that might help for ii = 1:5 end legend(hl)

4 years ago | 1508 views

Responded


Re: SVM classifier for ECG signals
You could start by downloading libsvm and reading the examples on how to use the MATLAB interface. No donations required, libs...

4 years ago | 3516 views

Posted


Readability of rotated text
Which format do you use? Sounds like you export a bitmap with very poor resolution. Many publications prefer figure files in eps...

4 years ago | 2807 views

Responded


Re: load multiple .mat files
Doc of load has a link to an example how to do that. At the bottom in section "How To" there is a link to "Processing a Sequence...

4 years ago | 1660 views

Responded


Re: Import Several Hundred .txt files
Processing a Sequence of Files" in the documentation: http://www.mathworks.com/help/techdoc/import_export/br5wz4t.html#br7q_u6

4 years ago | 2859 views

Responded


Re: find exact string in text
doc strfind "k = strfind(cellstr, pattern) searches each string in cell array of strings cellstr for occurrences of a shorter st...

4 years ago | 5464 views

Responded


Re: "boxplot.m" & Matlab R2012a
Are you sure you are using boxplot.m in the Stats toolbox? What does "which boxplot" tell you? In my R2012a line 154 of boxplot...

4 years ago | 2409 views

Responded


Re: delete rows of zeros in a matrix
For example B = A(any(A~=0,2),:) or A(all(A==0,2),:)=[]; Be careful with floating point numbers! Are they really zeros? You mig...

4 years ago | 12794 views

Responded


Re: Plotting values in boxes
If you want to have squares coloured by the values: doc imagesc If you want to print the the numeric values: doc text (and sprin...

5 years ago | 1207 views

Responded


Re: Extracting a value from a script file
Scripts evaluate in the main workspace. All the variables created in your scripts are available on the command line and in any ...

5 years ago | 994 views

Responded


Re: Matrix indices
Tell MATLAB debugger to stop at error and you can check what happens to your indices hth

5 years ago | 3216 views

Responded


Re: scatter too slow
Scatter creates separate patch objects for each data point. This only works for reasonable number of points. All we would need h...

5 years ago | 6165 views

Responded


Re: Using textscan function properly
You could use fgetl in a while loop to read line by line and check each line untill you find '<\EndOfHeader>'. Then continue w...

5 years ago | 2616 views

Responded


Re: Using textscan function properly
If the header is afixed number of lines in the beginning of the file you can skip them with the parameter ...'HeaderLines',

5 years ago | 2616 views

Responded


Re: textread help
Just a hint in case you haven't noticed in documentation of textread: Note textread will be removed in a future version. Use ...

5 years ago | 817 views

Responded


Re: (easy) plot in for loop
Depending on your needs there are probably better ways, but here is one. Define your plot options in a cell array of cells and u...

5 years ago | 1213 views

Responded


Re: How to use Latex in ticklabel?
There are several functions in the File Exchange that will do it for you.

5 years ago | 3257 views

Responded


Re: Increase matrix size
With the very basic indexing. You might want to read the Getting Started section in the docs. For example a = rand(64); % b = n...

5 years ago | 3465 views

Responded


Re: Out of memory Error
Just wondering why do you perform the same multiplication 40 times in the loop? Shouldn't 40*(b*a) give the same result? It doe...

5 years ago | 1267 views

Responded


Re: saving boxplots
Don't know. But one reason why the original example fails is that saveas accepts a handle of a figure or Simulink block diagram....

5 years ago | 3311 views

Posted


Read data
Please read the documentation for appropriate syntax to call datevec: doc datevec Plain string input should be one of the date ...

5 years ago | 593 views

Responded


Re: datenum & datestr does not match
The necessary help already exists in the documentation if you don't mind reading it. -> DateNumber = datenum(DateString) ... St...

5 years ago | 907 views

Posted


Replace fastly values in a HUGE matrix
That is not so huge, unless you have a typo in the size. Your code takes about 0.26 seconds on my laptop if there are about 100...

5 years ago | 2278 views

Responded


Re: How to convert data into libsvm format for classification
There is no need to convert your data if you use the MATLAB interface to LIBSVM. See the examples provided with LIBSVM.

5 years ago | 3414 views

Responded


Re: Specifiy Directory csvwrite
Yes, for example: mypath = 'C:\Users\ecorbett\Documents\MATLAB\Labelers\fred'; filename = 'Whatever'; csvwrite(fullfile(mypath,...

5 years ago | 6349 views

Responded


Re: LibSVM questions
Crossvalidation in LIBSVM returns only the CV-accuracy as its purpose is to help in selecting the parameters for the model. Then...

5 years ago | 2350 views

Responded


Re: function output
Other functions can't use the BW image returned by function 1 because that function doesn't return anything. After just a quick ...

5 years ago | 1388 views

Responded


Re: Indicator kriging
Never heard of such thing. Have you heard of Google? I was curious enough to try. It took about 15 seconds of googling to locate...

5 years ago | 2033 views

Responded


Re: MAT file size larger than workspace variable size
I have -v7 as default at the moment. Just try out and see what happens.

5 years ago | 3538 views

Load more