Hi, I would like to plot a linear relationship between variable x and y. Can anyone help me with scaled plotting and axes so that all data points can be visualized somehow evenly? Plaint plot(x,y) will generate condensed points near (0,0) due to several large data points. Thank you. Eric> x[1] 0.3497630 3.3948900 1.5224900 0.2690660 0.1078720 0.0451689 0.5902680 0.2757550 0.7518450 [10] 1.0059900 0.6524090 2.8066400 0.0269933 0.1373070 0.2829390 1.2300800 0.4364290 0.0555626 [19] 1.1062400 53.0000000 1.3041100 1.2974900 53.0000000 3.2552000 1.1890000 2.2361600 1.1325900 [28] 0.5050390 1.0581200 1.1823800 0.5009260 1.0314000 0.7334680 3.1329200 1.2668500 3.1088200 [37] 1.0171900 0.1309600 0.0529692 0.4184080 0.2132990 0.5366310 1.8233600 1.1528700 0.1925190 [46] 0.9612950 51.0000000 0.4705110 4.0568800 1.7809800 0.3646860 1.2453300> y[1] 0.423279 0.473681 0.629478 1.097120 0.396239 0.273577 0.303214 0.628386 0.465841 [10] 0.687251 0.544569 0.635805 0.358983 0.165190 0.366217 1.084210 0.668939 0.181861 [19] 0.782656 13.381600 1.152560 0.965943 20.000000 2.860510 0.304939 1.946540 0.967576 [28] 0.647599 0.520811 1.274340 0.363666 0.936210 0.544573 0.696733 1.003100 3.788950 [37] 0.694053 0.289111 0.178439 0.746576 0.391725 0.363901 1.202970 0.461934 0.364011 [46] 0.691368 20.000000 0.819470 1.695940 1.563810 0.900398 0.960948 [[alternative HTML version deleted]]
On Dec 23, 2010, at 5:37 PM, Eric Hu wrote:> Hi, > > I would like to plot a linear relationship between variable x and y. > Can anyone help me with scaled plotting and axes so that all data > points can be visualized somehow evenly? Plaint plot(x,y) will > generate condensed points near (0,0) due to several large data > points. Thank you. > > Eric > > >> x > [1] 0.3497630 3.3948900 1.5224900 0.2690660 0.1078720 > 0.0451689 0.5902680 0.2757550 0.7518450Rather than offering data in this format, which would require stripping out all of the element numbering at the margins, why not learn to post with dput values: dput(x) dput(y) # rather than #x #y -- David This message brought to you by the Committee for Better Posting Behavior.> [10] 1.0059900 0.6524090 2.8066400 0.0269933 0.1373070 > 0.2829390 1.2300800 0.4364290 0.0555626 > [19] 1.1062400 53.0000000 1.3041100 1.2974900 53.0000000 > 3.2552000 1.1890000 2.2361600 1.1325900 > [28] 0.5050390 1.0581200 1.1823800 0.5009260 1.0314000 > 0.7334680 3.1329200 1.2668500 3.1088200 > [37] 1.0171900 0.1309600 0.0529692 0.4184080 0.2132990 > 0.5366310 1.8233600 1.1528700 0.1925190 > [46] 0.9612950 51.0000000 0.4705110 4.0568800 1.7809800 > 0.3646860 1.2453300 >> y > [1] 0.423279 0.473681 0.629478 1.097120 0.396239 0.273577 > 0.303214 0.628386 0.465841 > [10] 0.687251 0.544569 0.635805 0.358983 0.165190 0.366217 > 1.084210 0.668939 0.181861 > [19] 0.782656 13.381600 1.152560 0.965943 20.000000 2.860510 > 0.304939 1.946540 0.967576 > [28] 0.647599 0.520811 1.274340 0.363666 0.936210 0.544573 > 0.696733 1.003100 3.788950 > [37] 0.694053 0.289111 0.178439 0.746576 0.391725 0.363901 > 1.202970 0.461934 0.364011 > [46] 0.691368 20.000000 0.819470 1.695940 1.563810 0.900398 > 0.960948 > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.David Winsemius, MD West Hartford, CT
Thanks David. I am reposting the data here. Eric> Hi, > > I would like to plot a linear relationship between variable x and y. > Can anyone help me with scaled plotting and axes so that all data > points can be visualized somehow evenly? Plaint plot(x,y) will > generate condensed points near (0,0) due to several large data > points. Thank you. > > Eric > > > dput(x)c(0.349763, 3.39489, 1.52249, 0.269066, 0.107872, 0.0451689, 0.590268, 0.275755, 0.751845, 1.00599, 0.652409, 2.80664, 0.0269933, 0.137307, 0.282939, 1.23008, 0.436429, 0.0555626, 1.10624, 53, 1.30411, 1.29749, 53, 3.2552, 1.189, 2.23616, 1.13259, 0.505039, 1.05812, 1.18238, 0.500926, 1.0314, 0.733468, 3.13292, 1.26685, 3.10882, 1.01719, 0.13096, 0.0529692, 0.418408, 0.213299, 0.536631, 1.82336, 1.15287, 0.192519, 0.961295, 51, 0.470511, 4.05688, 1.78098, 0.364686, 1.24533)> dput(y)c(0.423279, 0.473681, 0.629478, 1.09712, 0.396239, 0.273577, 0.303214, 0.628386, 0.465841, 0.687251, 0.544569, 0.635805, 0.358983, 0.16519, 0.366217, 1.08421, 0.668939, 0.181861, 0.782656, 13.3816, 1.15256, 0.965943, 20, 2.86051, 0.304939, 1.94654, 0.967576, 0.647599, 0.520811, 1.27434, 0.363666, 0.93621, 0.544573, 0.696733, 1.0031, 3.78895, 0.694053, 0.289111, 0.178439, 0.746576, 0.391725, 0.363901, 1.20297, 0.461934, 0.364011, 0.691368, 20, 0.81947, 1.69594, 1.56381, 0.900398, 0.960948)