Answered
how do I display all the text on one line?
Try this. filename = 'swire.pdf'; str = extractFileText(filename); c = regexprep(str,{char(13),char(10)}, ''); % or repla...

6 years ago | 1

| accepted

Answered
How can I generate selected number of tabs in tab group with app designer?
You're treating tab like a structure but it's a tab container object. Store the tab handles in a cell array. Here's a demo you...

6 years ago | 1

| accepted

Answered
ASCII coding to get corresponding character
You can use a switch/case or if/else as shown below. input is a scalar, integer value (not to be confused with the input() fun...

6 years ago | 0

Answered
find is not matching a value of 1 in an array
This is due to roundoff error. Here's a demo showing the roundoff error. k = linspace(0.1, 2.0, 20); % 1 is in positon 10...

6 years ago | 0

| accepted

Answered
How can I delete the same chunck from a column?
For table "T" and datetime column "Var1" T.Var1.Format = 'dd-MMM-yyyy';

6 years ago | 0

| accepted

Answered
How to export XaxisTick Labels which are cell arrays to figure or powerpoint in app designer?
@Rohit Deshmukh, please download and start using the new version of copyUIAxes() (verson 1.2.0, as of 19-Mar, 2020). I've upd...

6 years ago | 0

Answered
Fontsize and properties of Xticklabels using figure handles
"How do I cange the Xticklabels of a plot using figure handles?" Get the axis handle from the figure handle. ax = gca(figureH...

6 years ago | 2

| accepted

Answered
How to add the variables in a function to your workspace?
Add the variable as an output. function [y, c] = fun(x) c = . . . y = . . . end If you only want one of the outputs when...

6 years ago | 1

Answered
How can I print the result of a function using fprintf? (matrix and string!)
Put the data into a table and display the table. There are lots of way to create a table. Here's one way, data = [2 1 3; 3 1...

6 years ago | 0

Answered
From stuct to array
As stated in the documentation, the size of the vpasolve output corresponds to the number of the solutions. On the first iterati...

6 years ago | 1

| accepted

Answered
How do I set up a uigetdir with a Push button in appdesigner ?
Step 1: Add callback function to the Button Right click the button from within appdesigner and add a callback function. S...

6 years ago | 1

| accepted

Answered
Adding number within a range
no loop needed. my_sum = sum(1:a*b*c*d)

6 years ago | 0

| accepted

Answered
How to reshape a matrix
I would go with John D'Errico's approach (David Hill 's method is also good) but just to add another approach, A = [1,2,3,4 ; ...

6 years ago | 1

Answered
how can I combine 3 plane same figure
See hold on.

6 years ago | 0

| accepted

Answered
legend for plot3 command
Use the DisplayName property of graphics objects to specify the legend string. plot3(x,y,z, 'DisplayName', 'Object1'); hold on...

6 years ago | 1

| accepted

Answered
How to plot left semi_circle in matlab? (Given, x(origin), y(origin) and r(radius) of the circle)?
How to plot left semi circle: The key is to compute theta values between pi/2 and 3*pi/2. x=5; y=10; r=3; theta = l...

6 years ago | 0

| accepted

Answered
Vector Input, GUI edit text box
The string from a edit box is returned as a cell array of characters. If the expected inputs are a comma separated vector such a...

6 years ago | 1

| accepted

Answered
How to sort fastest and slowest reaction time?
See sort and sortrows.

6 years ago | 0

Answered
Subset timetable based on datetime values
Here's a demo that determines which rows of a timetable have times that are between two values. % Create a demo timetable TT ...

6 years ago | 0

| accepted

Answered
Saving data from nested for loop
Give this a shot. It's usually best to set up for-loops to iterate over integer values 1 to n. Those integer values can be used...

6 years ago | 0

| accepted

Answered
using RGB colour code while looping plots
Use one of the builtin colormaps or create your own nx3 RGB Color matrix where all values are between 0 and 1. col = parula(4)...

6 years ago | 1

| accepted

Answered
legend showing wrong colours
The easiest way to manage legend text is by using the DisplayName property of graphics objects. Here's how that might look when ...

6 years ago | 0

| accepted

Answered
A data is not calculated, while using rk4 code
"why is t not calculated/showed" It is shown. It equals 0. If you run the line below the extra space between the variable nam...

6 years ago | 0

| accepted

Answered
How to import axesm into app designer?
"...or how can I import a map axes into the app designer?" You can copy the content of a map axis to a UI Axis. Here's a demo....

6 years ago | 0

Answered
Plotting boxplot with distributions other than normal distribution
"[is it] possible to use boxplot or a similar plotting technique to plot data that are not normally distributed? " Yes. Is ...

6 years ago | 0

| accepted

Answered
calculating velocity from centroids
"I am now trying to calculate the velocity of all the particles through the video using centroid displacement. I know we can use...

6 years ago | 0

Answered
Adding multiple patch items to a plot
Here's a demo using the rectangel function. % Create x and y values. y = rand(1,100); x = linspace(0,10,100); % or x = 1:n...

6 years ago | 1

| accepted

Answered
How to scatter/plot a vector vs a cell array ?
w=[0, 0.1, 0.2, 0.3]; cellArray= {[3, -4, 5], [1], [-2], [3,3]}; figure() hold on % important arrayfun(@(i)plot(w(i),cellA...

6 years ago | 0

| accepted

Answered
Live line plotting over a surface/mesh/imagesc plot.
Here's a functional demo that uses the WindowButtonMotionFcn property of a figure to capture the mouse position which is used to...

6 years ago | 3

| accepted

Answered
random time series and regression models
You can use r = normrnd(mu,sigma,1,100) to generate 100 random numbers from a Gaussian distribution with mean mu and standard de...

6 years ago | 0

| accepted

Load more