MATLAB enthusiastic

Answered

How to mark the beginning and the end of a peak?

Peak Analysis can help you !!

How to mark the beginning and the end of a peak?

Peak Analysis can help you !!

3 days ago | 1

Answered

any output on command window

Probably all statements of your code terminated with the operator ;(semilocon) that means MATLAB doesnot show the computed resul...

any output on command window

Probably all statements of your code terminated with the operator ;(semilocon) that means MATLAB doesnot show the computed resul...

3 days ago | 0

Answered

Conversion of C++ code to matlab code

You have not used loop iteration varibales in C++ code?, anyway the plane conversion of your code is % using namespace std; %...

Conversion of C++ code to matlab code

You have not used loop iteration varibales in C++ code?, anyway the plane conversion of your code is % using namespace std; %...

3 days ago | 2

Answered

Random Sampling of Cell Array Variables which are not necessarily numeric

result = Answer{randi([1, 4])};

Random Sampling of Cell Array Variables which are not necessarily numeric

result = Answer{randi([1, 4])};

3 days ago | 0

Answered

How to filter data by date?

Suppose your timetable data in the variable td spring = td(timerange('2010-04-01', '2010-05-31'), :); % spring time data summ...

How to filter data by date?

Suppose your timetable data in the variable td spring = td(timerange('2010-04-01', '2010-05-31'), :); % spring time data summ...

4 days ago | 2

| accepted

Answered

sloution for my question

f = [20, 80, 120]; % your frequencies fs = 100; % sampling frequency t = 0:1/fs:1-1/fs; % time A = 1; % amplitud...

sloution for my question

f = [20, 80, 120]; % your frequencies fs = 100; % sampling frequency t = 0:1/fs:1-1/fs; % time A = 1; % amplitud...

4 days ago | 0

| accepted

Answered

Plotting data as points onto a previously generated graph

x = [ 233.0000 0.2200 253.0000 1.0571 257.0000 1.8943 237.0000 2.7057 229.0000 3.5171 242.0000 4.3286 2...

Plotting data as points onto a previously generated graph

x = [ 233.0000 0.2200 253.0000 1.0571 257.0000 1.8943 237.0000 2.7057 229.0000 3.5171 242.0000 4.3286 2...

4 days ago | 0

| accepted

Answered

How can I plot cosine/sine wave with exponential function?

Fs = 10000; % samples persecond t = (0:1/Fs:1-(1/Fs)); % seconds A = 1/2; % amplitude y = -A*cos(t)+A*exp(-t)+A*t.*exp(-t); ...

How can I plot cosine/sine wave with exponential function?

Fs = 10000; % samples persecond t = (0:1/Fs:1-(1/Fs)); % seconds A = 1/2; % amplitude y = -A*cos(t)+A*exp(-t)+A*t.*exp(-t); ...

7 days ago | 0

Answered

How to read multiple images from multiple folders and display them together?

selpath = uigetdir; % or selpath = '<your directory full path>'; n_images = 100; % number of images for ii = 1:n_images ...

How to read multiple images from multiple folders and display them together?

selpath = uigetdir; % or selpath = '<your directory full path>'; n_images = 100; % number of images for ii = 1:n_images ...

8 days ago | 0

| accepted

Solved

Alternate list of elements

Write a function that combines two lists by alternating the elements, e.g. ['a','b','c'], ['1','2','3'] → 'a1b2c3'.

8 days ago

Answered

How to scan text file?

data = readtable('yourfile.txt', 'Delimiter', ',',... 'HeaderLines', 0, 'ReadVariableNames',false, 'Format', '%d');

How to scan text file?

data = readtable('yourfile.txt', 'Delimiter', ',',... 'HeaderLines', 0, 'ReadVariableNames',false, 'Format', '%d');

9 days ago | 0

Answered

Find the maximum value in different vectors and from which vector is it?

max_val = max([v1, v2,v3]); % or max_val = max([v1(:);v2(:);v3(:)]); v1 = v1 == max_val; v2 = v2 == max_val; v3 = v3 == max_v...

Find the maximum value in different vectors and from which vector is it?

max_val = max([v1, v2,v3]); % or max_val = max([v1(:);v2(:);v3(:)]); v1 = v1 == max_val; v2 = v2 == max_val; v3 = v3 == max_v...

10 days ago | 1

| accepted

Answered

conversion from double to cell is not possible

I don't know what you are trying to do with given code, if I assume by name of the mentioned function name "sparse to matrix con...

conversion from double to cell is not possible

I don't know what you are trying to do with given code, if I assume by name of the mentioned function name "sparse to matrix con...

12 days ago | 0

Answered

Sequence Generation of a table

First 4 columns follows truth table notation values and next two columns are one, n = 4; % truth table size header = {'PL100'...

Sequence Generation of a table

First 4 columns follows truth table notation values and next two columns are one, n = 4; % truth table size header = {'PL100'...

12 days ago | 0

Answered

how to change font size of bus number in graph

This answer can fullfill your requirement https://in.mathworks.com/matlabcentral/answers/450580-change-font-size-of-node-name-...

how to change font size of bus number in graph

This answer can fullfill your requirement https://in.mathworks.com/matlabcentral/answers/450580-change-font-size-of-node-name-...

13 days ago | 0

| accepted

Answered

how do i read random jpeg frames from a folder?

% assuming your image file names are in sequence as 1.jpg,2.jpg,..., 2000.jpg n_imges = 10; % number of random images you wa...

how do i read random jpeg frames from a folder?

% assuming your image file names are in sequence as 1.jpg,2.jpg,..., 2000.jpg n_imges = 10; % number of random images you wa...

14 days ago | 0

| accepted

Answered

why does matlab use 8 bytes to memorize a number like 1 for example

MATLAB software takes the defualt value storage memory for numeric a value is double precision floationg value that is 64 bit v...

why does matlab use 8 bytes to memorize a number like 1 for example

MATLAB software takes the defualt value storage memory for numeric a value is double precision floationg value that is 64 bit v...

14 days ago | 0

Answered

Plotting Issue with code

MATLAB operator "/" does Solve systems of linear equations, use "./" operator instead for element wise division operation funct...

Plotting Issue with code

MATLAB operator "/" does Solve systems of linear equations, use "./" operator instead for element wise division operation funct...

17 days ago | 0

Answered

cell to a matrix

Your FV1 matrix has empty cells this leads to dimension concatenate consistent error so you need to replace those empty cells wi...

cell to a matrix

Your FV1 matrix has empty cells this leads to dimension concatenate consistent error so you need to replace those empty cells wi...

18 days ago | 0

| accepted

Answered

How to find Distance Between two points ?

a = [ 0.1, 0.1, 0.2, 0.5, 0.22]; % your vector dist = cell(1, length(a)-1); % your distance cell matrix empty initializ...

How to find Distance Between two points ?

a = [ 0.1, 0.1, 0.2, 0.5, 0.22]; % your vector dist = cell(1, length(a)-1); % your distance cell matrix empty initializ...

18 days ago | 0

Answered

New to Matlab- How to import a text file for analysis that contains numbers and characters?

Using textscan command you can get the required data from the input text file, data would be extracted in the cell data type tr...

New to Matlab- How to import a text file for analysis that contains numbers and characters?

Using textscan command you can get the required data from the input text file, data would be extracted in the cell data type tr...

21 days ago | 0

Answered

a Simple Matrix question

Matrix_C = matrix_A; matrix_C(ismember(matrix_A, Matrix_B)) = 255;

a Simple Matrix question

Matrix_C = matrix_A; matrix_C(ismember(matrix_A, Matrix_B)) = 255;

21 days ago | 0

Answered

Merging Arrays in a Struct and Sorting them

result = sort(struct2array(v), 'ascend')

Merging Arrays in a Struct and Sorting them

result = sort(struct2array(v), 'ascend')

22 days ago | 0

| accepted

Answered

Combining multiple plots in 1 graph

I have used for loops to read and plot signals % filename = 't1-1.txt'; % assuming your files are in present working directory...

Combining multiple plots in 1 graph

I have used for loops to read and plot signals % filename = 't1-1.txt'; % assuming your files are in present working directory...

22 days ago | 0

| accepted

Answered

How would I create a matrix from the following strings

data = fileread('ThinPlateNodes.txt'); % read file(it is in text) ext_data = regexp(data, '[^{\]]+(?=})', 'match'); % get data...

How would I create a matrix from the following strings

data = fileread('ThinPlateNodes.txt'); % read file(it is in text) ext_data = regexp(data, '[^{\]]+(?=})', 'match'); % get data...

22 days ago | 1

| accepted

Answered

How to include header text in a Table when writing to Excel?

In table to array conversion only one type of the data will be displayed, head(string) would skipped. If you want to write dat...

How to include header text in a Table when writing to Excel?

In table to array conversion only one type of the data will be displayed, head(string) would skipped. If you want to write dat...

22 days ago | 0

| accepted

Answered

Read a file contains hexdecimal complex numbers, and convert decimal complex numbers

data = fileread('real_imag.txt'); % read data in all char data_hex = regexp(data, '[\d\w]*', 'match'); % divide all into ...

Read a file contains hexdecimal complex numbers, and convert decimal complex numbers

data = fileread('real_imag.txt'); % read data in all char data_hex = regexp(data, '[\d\w]*', 'match'); % divide all into ...

24 days ago | 0

| accepted

Answered

help!!! with plot

MATLAB operator "/" performs linear equation solver, apply dot elemetwise(./) division clear; a=200;b=5;cm=10;cr=3;v=600;k=6;...

help!!! with plot

MATLAB operator "/" performs linear equation solver, apply dot elemetwise(./) division clear; a=200;b=5;cm=10;cr=3;v=600;k=6;...

24 days ago | 0

Answered

Combine variables with different number of element in cell

You can write the data using tablewrite, onsets{1} = [84.0190 156.0190 192.0190 266.0190 84.0190 156.0190 192.0190 266...

Combine variables with different number of element in cell

You can write the data using tablewrite, onsets{1} = [84.0190 156.0190 192.0190 266.0190 84.0190 156.0190 192.0190 266...

25 days ago | 0