Respondida
how to import data
Doc says: Import Numeric Data from a Text File You can import any ASCII data file with numeric fields easily ...

más de 14 años hace | 0

Respondida
finding the top ten values of arrary
Try this: %% M = magic(4); N = 10; %% [ b, ix ] = sort( M(:), 'descend' ); %% [ rr, cc ] = ...

más de 14 años hace | 1

| aceptada

Respondida
how to count the match
I guess that if you are not more specific you'll get an answer like this :) number_of_matches = 0; ... if ...

más de 14 años hace | 0

Respondida
how read this txtfile?
This is a start. Add a loop and fgetl. %% str = '1|Toy Story (1995)|01-Jan-1995||http://us.imdb.com/M/title-exact?Toy%2...

más de 14 años hace | 0

| aceptada

Respondida
How to pull files from mutiple folders
See the FEX contributions: * <http://www.mathworks.se/matlabcentral/fileexchange/32226-recursive-directory-listing-enhanced-r...

más de 14 años hace | 0

Respondida
Textscan skipping character 'd'
Try: DepVar = textscan( fileName, 'Br%u%[THAMS]%d%c%*s' ); . *--- Response to comment ---* I cannot reproduce th...

más de 14 años hace | 0

Respondida
Loading ASCII tables into MATLAB as strings to be processed
I assume that your data is in a text file. This code will read the file fid = fopen( 'cssm.txt' ); cac = textscan(...

más de 14 años hace | 0

| aceptada

Respondida
List all variables in a mfile
I think it is possible to do automatically. Idea: * set a conditional break point at the last line of every function. Hopeful...

más de 14 años hace | 3

| aceptada

Respondida
Data extraction from a text file.
If all lines have the same format try data=textscan(fid,':%f'); *--- Cont. ---* This work with R2012a fid = ...

más de 14 años hace | 0

Respondida
Text output keeps repeating
When debugging did you inspect the value of output? The code you show can hardly give multiple groups of lines. The values of ro...

más de 14 años hace | 0

Respondida
how works with parallel processing?
See: <http://www.mathworks.se/products/parallel-computing/ Parallel Computing Toolbox> and return with more specific questions....

más de 14 años hace | 1

| aceptada

Respondida
encryption of .mat files
Matlab documentation: New MAT-File Format Based on HDF5 In Version 7.3 (R2006b), you can save MAT-files in a format ...

más de 14 años hace | 0

Respondida
Why is the "state" important?
Start reading here: <http://blogs.mathworks.com/loren/2008/11/05/new-ways-with-random-numbers-part-i/ New Ways With Random Num...

más de 14 años hace | 0

| aceptada

Respondida
how to put different colors for different bars for barh function.
Study this and note especially the length and values of neworder, neworder1 and neworder2 in your and my revised code. ...

más de 14 años hace | 0

| aceptada

Respondida
Can I find out if a class is an abstract class before trying to instantiate it?
A class is abstract if any of its properties or methods is abstract. It's possible to write a function, is_abstract. Start: ...

más de 14 años hace | 0

| aceptada

Respondida
Remove all fields from a struct except if
MATFILE is the closest there is to your requirement. And it is a rather new feature. I use R20012a. %% N = 8; m...

más de 14 años hace | 2

| aceptada

Respondida
erasing all the rows of a cell matrix that contain a specific string variable
Your solution is based on an undocumented behavior of strcmp. strcmp according to the documentation should not take a double nor...

más de 14 años hace | 0

| aceptada

Respondida
Load different files then converting them into .txt files
Make a a cell array of strings: a={'20MIN_SCHJ300639_220208.mat' '20MIN_SEMS170640_040608.mat' '20MIN_SIMG200162_060208.m...

más de 14 años hace | 0

| aceptada

Resuelto


Return unique values without sorting
If the input vector A is [42 1 1], the output value B must be the unique values [42 1] The *values of B are in the s...

más de 14 años hace

Respondida
Processor usage
In discussions on performance of Matlab version of Matlab, the OS and the use of the Parallel Toolbox are all important. ...

más de 14 años hace | 0

Respondida
'For loop' for beginners
No need for a loop: positive_numbers = v(v>0); negative_numbers = v(v<0); zero_numbers = v(v==0); . S...

más de 14 años hace | 0

| aceptada

Respondida
Using while loop to analyze cell array
Why a cell array of numeric data rather than a numeric array? Many questions are about removing loops. Why a while-loop? This...

más de 14 años hace | 0

| aceptada

Respondida
Problems writing to text files
I have R2012a 64bit, Windows7. I tried your code with some data. The resulting file looks ok in Notepad++, but as you descri...

más de 14 años hace | 1

Respondida
how to create shortcut for "brushing/create new variable"
Did you search the FEX? You might want to try <http://www.mathworks.com/matlabcentral/fileexchange/13857-graphical-data-selectio...

más de 14 años hace | 0

Respondida
position of maximum in matrix
Help says: C = max(A,[],dim) returns the largest elements along the dimension of A specified by scalar dim. For exa...

más de 14 años hace | 0

Resuelto


Multiply 2 numbers
Very easy, you just have to multiply 2 numbers but you cannot use the following signs (*, /, - ,^) ,mtimes , times, cross, pro...

más de 14 años hace

Respondida
Problems with Datenum / Datestr to convert times and dates to serial time and dates
Try %% data = {'17:05:38', '06/27/12' '17:05:42', '06/27/12' }; %% out = [ datenum(data(:,1),'HH...

más de 14 años hace | 0

Respondida
how to make monthly graph from daily file data
Here is a function that returns total monthly rain. Try >> mr = MonthlyRain( RainData ); >> plot( mr(1).Rain, 'd' ); ...

más de 14 años hace | 2

| aceptada

Respondida
how to make monthly graph from daily file data
Here is a function that collects total daily rain for one month at a time. Try >> [ day_number, daily_rain ] = DailyRain( R...

más de 14 años hace | 3

Respondida
how to read x file data (x=30file)
Try ix_day = 1; plot( datenum( RainData( ix_day ).Datevec ), RainData( ix_day ).Rain ) datetick title( sp...

más de 14 años hace | 1

Cargar más