Respondida
How to plot the real and imaginary parts of a signal using subplot function.
Ok, you're pretty much there already. Just a few things: plot t on the x-axes title the plots t = 0:0.1:10; a = cos(pi./6*t)...

más de 6 años hace | 0

| aceptada

Respondida
How to add a line after every seventh Value!
You can add vertical lines using xline: % create sample data x = 1:2544; y = rand(1,length(x)); % store indices that will be...

más de 6 años hace | 0

Respondida
name as representing numbers
I think the only change you need from Image Analyst's is to subtract off the (numeric code for the) first letter of the name, ra...

más de 6 años hace | 1

Respondida
Integration of numerical data
It does not appear that trapz ignores negative data. Instead, I think you just need to give it your time data so that it can acc...

más de 6 años hace | 0

| aceptada

Respondida
Problem in output. Output Truncated. Text exceeds maximum line length of 25,000 characters for Command Window display
Instead of displaying the results and copying, print them directly to a file. The best format depends on how you will be working...

más de 6 años hace | 0

| aceptada

Respondida
How to write a quadratic equation solver using vectors
Search the help for one of the other students asking how to solve this exact same problem

más de 6 años hace | 0

Respondida
How to plot a combination of product and devision of some vectors
Set up an example problem: x=rand(1,1000); y=rand(1,1000); z=rand(1,1000); t = [1:1000]/1000; % calculate your function ...

más de 6 años hace | 0

| aceptada

Respondida
Visualizing values of nodes in a graph
Fix the axis limits right after creating the colorbar: colorbar caxis([1 100])

más de 6 años hace | 0

Respondida
How do I compare two sentences with similar words?
First, split each sentence into the individual words words_1 = split(string1,[" ",","]); words_2 = split(string2,[" ",","]); ...

más de 6 años hace | 0

| aceptada

Respondida
Calling videos from a folder in every iteration
Putting I(k) in quotes makes Matlab read it as a char instead of a variable. It is literally looking for I(k).mp4. To use the va...

más de 6 años hace | 1

| aceptada

Respondida
How can I automatically set a plots xlabel and ylabel to the variable names of x and y, when x and y are structure fields?
Assuming your data will always be in two fields of the same structure: function myscatter(data,x_field,y_field, varargin ) ...

más de 6 años hace | 2

| aceptada

Respondida
Index in position 2 exceeds array bounds
scanvecs is a 1xl cell, so what=scanvecs(l); makes "what" also a 1x1 cell (containing the last set of data). Indexing what(:,2...

más de 6 años hace | 0

Respondida
I have been using the nchoosek function to find combinations of subset of elements, but for large numbers 40C20 its is very slow .
Is it slow or frozen or error-ing? There are 137846528820 (~1e11) possible combinations (40 choose 20), so you are asking for...

más de 6 años hace | 1

| aceptada

Respondida
How to delete similar data from big data file?
Looking into it a bit (I have a similar problem), it seems like there is a way using the "Split-Apply-Combine Workflow". It is f...

más de 6 años hace | 0

Respondida
how do i use integrated web cam for live video processing in matlab?
Here's a pretty cool example of what you can do https://www.mathworks.com/help/deeplearning/examples/classify-images-from-webca...

más de 6 años hace | 0

Respondida
How to do n-loops and store results of each loop in array
My reading: you want to execute the above section of code in an additional for loop, and store TP, FP, TN, FN for each loop? Doe...

más de 6 años hace | 0

Respondida
How to delete similar data from big data file?
Alright, here's my solution. Its speed depends on how often you expect duplicates (controlled in test by test_vals). I ran a tes...

más de 6 años hace | 0

Respondida
equalizing person heights in an image
Assuming you have a nice image like this, with white space around all the people, I think the following algorithm should work. I...

más de 6 años hace | 1

Respondida
what functions are no longer supported in 2018b?
Here are the release notes, filtered to incompatibility issues between 2011a and 2018a. If you are using toolboxes, you can chec...

más de 6 años hace | 0

Respondida
Plot different color data range
Based on this answer: https://www.mathworks.com/matlabcentral/answers/1156-conditional-plotting-changing-color-of-line-based-on-...

más de 6 años hace | 0

Respondida
Detect sign change in Matlab
A method safe against overflow. counting zeros as not a sign change Sign changes: if sign(prior_value)*sign(current_value) ==...

más de 6 años hace | 1

Respondida
Trouble using suplabel() to create global axes for figure with multiple subplots
sublabel does not exist in Matlab releases. You can download the user-created sublabel from the File Exchange and put it on your...

casi 7 años hace | 0

Respondida
Avoid colorbar resizing image
If you set the position of the colorbar manually, the figure won't be resized. So: cb=colorbar; cb.Position = cb.Position + 1e...

alrededor de 7 años hace | 7

Respondida
How can I export a matrix as a CSV file?
It sounds like all you need to do is print a column vector instead of a row vector. This can be done easily: csvwrite('test.txt...

alrededor de 7 años hace | 2

Respondida
replicating the elements of a cell matrix
repelem(k,2,1)

más de 7 años hace | 0