Question

matlab keep ignoring negative values when i plot the data.... what should i do to plot...

matlab keep ignoring negative values when i plot the data....

what should i do to plot negative numbers...

Homework Answers

Answer #1

Here is one of the example to plot the negative value, I used "axis" function.

tt = -0.00025:0.00001:0.00025;// setting the time axis
y1 = 20*cos(2*pi*(2000)*(tt -37.2/10));//one of the function
tt = -0.00025:0.00001:0.00025;// setting the time axis
y2 = 14*cos(2*pi*(4000)*(tt +41.3/10));//
y3= y1+y2;//An operation on signal
subplot(3,1,1)
plot(tt,y1)
title('Y1')
xlabel('Time')
axis([min(tt) max(tt)    ylim])
subplot(3,1,2)
plot(tt,y2)
title('Y2')
xlabel('Time')
axis([min(tt) max(tt)    ylim])
subplot(3,1,3)
plot(tt,y3)
title('Y3')
xlabel('Time')
axis([min(tt) max(tt)    ylim])
Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
MATLAB** I'm not sure what I'm doing wrong writing out my equation. I keep getting an...
MATLAB** I'm not sure what I'm doing wrong writing out my equation. I keep getting an error. It has something to do with the line with the function written out. Here's what I have: %3.2 clc clear close all %plot ?(?,?)=?(1+sin?), as a 3D plot on the domain ?∈[−8,8], ?∈[−8,8]. x=[-8:8]; y=[-8,8]; z=x(sin(y)+1); plot3(x,y,z) title('Plot 3.2')
Download the Matlab data set data.mat. It contains a DTMF signal with six numbers dialed in...
Download the Matlab data set data.mat. It contains a DTMF signal with six numbers dialed in sequence. Find the phone number dialed. Data file contains value for Fs = 8000 and 14,400 values for x. Create a Matlab code that will either plot the phone number or solve for it if x and Fs are entered. No additional informafion is needed. User will load a .mat or .wav file containing x values and Fs value.
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should...
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should be indicated by a minus sign. Round your answers to 3 decimal places.) X: 6,5,3,6,10 Y: 6,6,4,7,7 a. Determine the 0.95 confidence interval for the mean predicted when x = 9. b. Determine the 0.95 prediction interval for an individual predicted when x = 9.
I believe this is fairly easy but I am not very fond in Matlab so please...
I believe this is fairly easy but I am not very fond in Matlab so please help me out: I need to plot a contour in MATLAB basically seeing what values of two variables throughout the spectrum get the result. Here is the question. I will post equations to find the values of each part below. Question: Write a Matlab code that plots a single contour (which is based on the specific energy calculated at part (a)). Note that the...
I am to create a scatter plot with two sets of data (there is a lot...
I am to create a scatter plot with two sets of data (there is a lot more data than what is posted below but the whole data set was too large to post).  I am then to complete a Pearson R test for significance and test for goodness of fit using R2. How do I create a scatter plot with the data? How do I complete the required tests of the data?   Score # BSN Pearson r 536.17 5 T .DIST...
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should...
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should be indicated by a minus sign. Round your answers to 3 decimal places.) X: 5 5 2 6 10 Y: 4 6 5 5 7    Determine the 0.99 confidence interval for the mean predicted when x = 7.
Could you please explain me why an when do I have to use the negative binomial...
Could you please explain me why an when do I have to use the negative binomial distribution for Problem 15 in chapter 2 (rice- mathematical statistics and Data Analysis 3rd Edition). I wanted to use the normal binomial distribution but I come to the wrong results....
What do I do when my Welch test and Mann-Whitney tests have conflicting p-values/ interpretations? Independent...
What do I do when my Welch test and Mann-Whitney tests have conflicting p-values/ interpretations? Independent Samples T-Test Test Statistic df p Lead_Measured_(mg/kg) Student -2.048 90.000 0.044 Welch -2.048 64.477 0.045 Mann-Whitney 920.500 0.285 Table 3. A Student, Welch, and Mann-Whitney t-test. This is what I have collected from my data, and I do not know how to properly interpret it. My confidence level is 95% with and alpha value of 5%.
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should...
The following sample observations were randomly selected. (Do not round the intermediate values. Negative amount should be indicated by a minus sign. Round your answers to 3 decimal places.) x y 6 4 4 6 1 5 6 4 10 9 Determine the 0.90 confidence interval for the mean predicted when x = 8. Determine the 0.90 prediction interval for an individual predicted when x = 8.
Plot the following data and then calculate and plot a three-period moving average. then calculate and...
Plot the following data and then calculate and plot a three-period moving average. then calculate and plot a five-period moving average. What do you observe in comparing the plots of he three and five period moving averages? period 1 2 3 4 5 6 7 8 9 10 demand 60 52 55 42 57 33 26 42 35 31 Develop a forecast for period 11 using expontentional smoothing and three values of alpha: .05, .30 and .90 Plot actual data...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT