I want to plot 2 subplots both being histograms. For the first set, I want there to be 0.2 increments starting at 22, then, 22.2, 22.4, etc. until 34.
Same for the second set, except different limits based on the data I had on file.
Problem: When I graph this, the tick marks for suplot 1 is: [22.00 24.00, ... 34.00] But when squinting I can see the graph really is spaced out 0.2.
Same for second subplot except spaced out 0.25. How do I correct my code below?
I found I should use gca, but it doesn't seem to be working. Where should I add:
ax = gca;
load data1.txt; %load text file while has 200 rows of data with 2 columns
x = data1(:,2); % take all rows in col 1
y = data1(:,1); %take all rows in col 2
histogram(x, [22: 0.2: 34]) %the 22 to 34 is just the x limits I set for the data
histogram(y, [-1.5: 0.25: 1.5]) %change limits for your set of data.