Solved


Create a cell array out of a struct
Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column: in: ...

6 years ago

Solved


Convert a Cell Array into an Array
Given a square cell array: x = {'01', '56'; '234', '789'}; return a single character array: y = '0123456789'

6 years ago

Solved


Remove element(s) from cell array
You can easily remove an element (or a column in any dimension) from a normal matrix, but assigning that value (or range) empty....

6 years ago

Answered
How to store results of a Structure
Convert to the cell array as get_FileNames = {info_h5.stuff.morestuff.FileNames}; % enclosed in {} brackets then access the...

6 years ago | 1

| accepted

Solved


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for.

6 years ago

Answered
how can i give the variable of a slider to another function?
In the end of evert UI control funtion make a statement as guidata(hObject,handles); % which enables the to pass/updates var...

6 years ago | 0

Answered
How to realize this cycle in MatLab?
In MATLAB no need of variable definations you can directly initialize x = rand(1,100);% fake data 1x100 random float numbers ...

6 years ago | 0

| accepted

Solved


Natural numbers in string form
Create a cell array of strings containing the first n natural numbers. _Slightly_ harder than it seems like it should be. Ex...

6 years ago

Solved


String Array Basics, Part 1: Convert Cell Array to String Array; No Missing Values
<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

6 years ago

Solved


Cell Counting: How Many Draws?
You are given a cell array containing information about a number of soccer games. Each cell contains one of the following: * ...

6 years ago

Answered
Returning to start of statement if error
while 1 [file,path] = uigetfile('*.CSV'); % Prompting the user to select a .CSV file from their directory if isequal(f...

6 years ago | 1

| accepted

Answered
Bar plots side by side in order to compare two results
You can display in many ways out of these stating two ways % side by side bar([Main_Result', Simulated_Result']), legend('Mai...

6 years ago | 0

| accepted

Solved


Find the maximum number of decimal places in a set of numbers
Given a vector or matrix of values, calculate the maximum number of decimal places within the input. Trailing zeros do not coun...

6 years ago

Solved


Make roundn function
Make roundn function using round. x=0.55555 y=function(x,1) y=1 y=function(x,2) y=0.6 y=function(x,3) ...

6 years ago

Answered
how to insert a value into the array in a consistent manner.
Are you asking for this ? A = ones(3, 1); if (size(A,2)>1) A = [0 A]; else A = [0;A]; end

6 years ago | 0

Solved


Matlab Basics - Rounding III
Write a script to round a large number to the nearest 10,000 e.g. x = 12,358,466,243 --> y = 12,358,470,000

6 years ago

Solved


Matlab Basics - Rounding II
Write a script to round a variable x to 3 decimal places: e.g. x = 2.3456 --> y = 2.346

6 years ago

Solved


Check that number is whole number
Check that number is whole number Say x=15, then answer is 1. x=15.2 , then answer is 0. <http://en.wikipedia.org/wiki/Whole...

6 years ago

Solved


MATLAB Basic: rounding IV
Do rounding towards plus infinity. Example: -8.8, answer -8 +8.1 answer 9 +8.50 answer 9

6 years ago

Solved


MATLAB Basic: rounding III
Do rounding towards minus infinity. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 8

6 years ago

Solved


MATLAB Basic: rounding II
Do rounding nearest integer. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 9

6 years ago

Solved


MATLAB Basic: rounding
Do rounding near to zero Example: -8.8, answer -8 +8.1 answer 8

6 years ago

Answered
how to solve 'Error using | Matrix dimensions must agree. ' ?
You have used mrdivide not normal division here. correct one is clc; clear all; T=0:0.001:0.07; size(T); cm=1.; lo=-3.545-...

6 years ago | 0

Answered
[U,V]=eig(A) , AU won't equal UV
In general terms A*U and U*V are equal but in MATLAB it computes with difference in decimal points almost at 15th decimal value ...

6 years ago | 0

| accepted

Answered
Help With error code "WIDTH cannot be larger than the number of points."
See the help of controlchart plot_handle = controlchart([machine_1]', 'charttype', {'xbar', 'r'}'); % applied compliment to ...

6 years ago | 2

| accepted

Solved


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

6 years ago

Solved


Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...

6 years ago

Solved


Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

6 years ago

Solved


Doubling elements in a vector
Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

6 years ago

Solved


Create a vector
Create a vector from 0 to n by intervals of 2.

6 years ago

Load more