similar to: problem with abline and lines

Displaying 20 results from an estimated 20000 matches similar to: "problem with abline and lines"

2012 Jul 12
2
trellis margin sizes in absolute units
Dear R users, I have a lot of experience with traditional R graphics, but I decided to turn to trellis as it was recommended for spatial graphs by the sp package. In traditional R graphics I always first set the size of the device region absolute units (e.g. mm) and then I firmly fix the inner margins with mai and the outer margins with oma also in absolute units. What is left from the device
2007 Oct 11
5
rearrange data columns
Dear R users, I need to to the the following. Let a= 1 2 3 4 5 6 and b= -1 -2 -3 be (2x3) matrices. -4 -5 -6 I need to combine the two matrices into a new (2x6) matrix like this: ab = ( 1 -1 2 -2 3 -3 ) 4 -4 5 -5 6 -6 How can this be done in R? ----------------------------------------------------------------- ?????? ???
2007 Jan 29
2
Need to fit a regression line using orthogonal residuals
I'm trying to fit a simple linear regression of just Y ~ X, but both X and Y are noisy. Thus instead of fitting a standard linear model minimizing vertical residuals, I would like to minimize orthogonal/perpendicular residuals. I have tried searching the R-packages, but have not found anything that seems suitable. I'm not sure what these types of residuals are typically called
2016 Apr 28
1
polygon angle option perpendicular to axis
The angle is not based on the polygon edges, but it can seem that way if you do not use the asp=1 argument in your plot. Try this example, > plot(1:10, 1:10, type='n') > x <- c(1, 3, 5, 3) > y <- c(3, 5, 3, 1) > polygon(x, y, angle=0, density=10) > polygon(x, y + 4.5, angle=45, density=10) > polygon(x + 4.5, y + 4.5, angle=90, density=10) > polygon(x + 4.5, y,
2009 May 24
2
A question on type="h" plot lines
Dear R users, I need a produce a plot with a single panel and a few lines on it. Each line represents a different data set. The line types must be "h", i.e. ?histogram? like (or ?high-density?) vertical lines. The problem is that the vertical lines comprising a plot line of type="h" are drawn from the y=0 line to the (x, y) locations. What I need is vertical lines drawn from
2007 Oct 13
2
a question on impulse responses
Dear R users, I am using the vars package to calculate the impulse response functions and the forecast error variance decomposition of a VAR model. Unfortunately I do not know whether these functions assume unit or one standard deviation shocks. I tried to look into the code of these functions, but in vain: neither irf, nor vars::irf, nor vars:::irf output the code of the functions. Does someone
2010 Aug 23
4
Draw a perpendicular line?
Hi, I am trying to draw a perpendicular line from a point to two points. Mathematically I know how to do it, but to program it, I encounter some problem and hope can get help. Thanks. I have points, A, B and C. I calculate the slope and intercept for line drawn between A and B. I am trying to check whether I can draw a perpendicular line from C to line AB and get the x,y value for the point D
2012 Nov 25
3
Comparing linear regression coefficients to a slope of 1
Hi! I have a question that is probably very basic, but I cannot figure out how to do it. I simply need to compare the significance of a regression slope against a slope of 1, instead of the default of zero. I know this topic has been posted before, and I have tried to use the advice given to others to fix my problem. I tried the offset command based on one of these advice threads as follows:
2016 Apr 28
0
polygon angle option perpendicular to axis
Filling polygons with lines is a throwback to the time when the height of quality graphics was the mechanical pen plotter (a device that used a pen in a mechanical arm to draw the plot on a piece of paper). Computing and printing technology has advanced quite a bit from that day, so you may want to reconsider why you want polygons filled with lines instead of just a solid color (and I consider
2016 Apr 27
4
polygon angle option perpendicular to axis
I am trying to use the angle option in polygon to create polygons filled with horizontal and vertical lines. The polygons I am crating are irregular and it the angle function appears to set the angle of the shading perpendicular to the polygon sides rather than perpendicular to the axes. Is there any way to set the angle relative to the axes rather than relative to the polygon sides?
2007 Oct 12
1
calculate impulse responses
Dear R users, I need perform structural analysis on a no intercept VAR model. Unfortunately the functions irf.VAR and dfev that come with the MSBVAR package only work with objects output by the reduced.form.var function, which seems to only evaluate VAR models with intercept. Is there a way to suppress the estimation of intercept term in reduced.form.var? Do I need to modify the code, and if I
2006 Aug 16
5
Master privileges unavailable on UPS, no access :(
Hello! After I type "upsmon", in syslog the following message appears: Aug 16 14:11:09 marto upsmon[7731]: Master privileges unavailable on UPS [Inform@localhost] Aug 16 14:11:09 marto upsmon[7731]: Reason: Access denied Can you tell me where my error is, my configuration files are: ups.conf: [Inform] driver = powercom port = /dev/ttyS0 desc = "inform guard" linevoltage = 220
2013 Nov 19
2
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Eric Recordé un ejemplo rápido ## Setup up coordinate system (with x == y aspect ratio): plot(c(-2,3), c(-1,5), type = "n", xlab = "x", ylab = "y", asp = 1) ## the x- and y-axis, and an integer grid abline(h = 0, v = 0, col = "gray60") text(1,0, "abline( h = 0 )", col = "gray60", adj = c(0, -.1)) abline(h = -1:5, v = -2:3, col =
2011 Jun 29
1
tcgetattr: Inappropriate ioctl for device
Dear nut users, I am running nut-2.6.0 on Slackware-Linux-13.37.0 with kernel 2.6.37.6. I am trying to get the software work for a repotec UPS with model name: RPT-1003AU. The UPS communicates with the computer via USB. I know that the model is not officially supported but I want to try out whether it will work with some of the repotec drivers. Here is the result with the genericups upstype=13
2013 Nov 16
3
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Estimados, tengo un grafico al que agregue una linea con abline(), este es el codigo ... library(Hmisc) # agregar una linea horizontal con el valor del angulo de contacto del control trellis.device(color = FALSE) xYplot(Cbind(ca.med[,3],ca.med[,5],ca.med[,6])~ca.med[,2], groups=Sol, data=ca.med, xlab=list(label="Concentration (mM)", cex=1.3), ylab=list(label="Contact Angle
2007 Jan 18
1
weighted MDS, alscal
Hello! I need to perform weighted multidimensional scaling analysis(WMDS). I did rsitesearch, googled, but I could find no info on how to perform WMDS using R. In several places they say it is possible with the ALSCAL algorithm, but I could not find the relevant function to carry it out. ----------------------------------------------------------------- ???????? ?? ??????? ?? ??? ???????????!
2010 Jan 27
1
biplot from stats: 0.8 ?
Dear forum, I need to create biplot graphic. I took a look at the code of the biplot.default function from the stats package and I found that the arrows for the variables are multiplied by a coefficient of 0.8 before plotting: ... if (var.axes) arrows(0, 0, y[, 1L] * 0.8, y[, 2L] * 0.8, col = col[2L], length = arrow.len) ... I have no idea why this is done. Could somebody
2013 Nov 19
1
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Estimado Eric En Hmisc la función labcurve puede ser útil, en todos casos crear una curva con valores constantes, habría que intentar, pero labcurve en algunos ejemplos en mi computadora no anda. Ayer envié dos correos, el primero era de latticeextra, usted nombra lattice, pero podría funcionar, en latticeextra: ## horizontal and vertical lines xyplot(ysim ~ xsim) + layer(panel.ablineq(v
2004 Mar 19
5
asp=1 and aspect ratio
Hi everyone I want a square scatterplot with abline(0,1) going exactly through the SW and NE corners. By "square" I mean that the plotting region is exactly square, and that the axis limits are identical. x <- 1:20 y <- x+rep(c(-1,1),10) lims <- range(c(x,y)) None of the following do this: plot(x,y) ; abline(0,1) #not square plot(x,y,asp=1);abline(0,1) #diagonal
2010 Oct 06
4
problem with abline
Hi All, I am running a scatter plot and trying to add a best fit line. I use an abline function, but get no line drawn over the points. I also get no error. I arm using V 2.10.0 on Windows 7. Here is my code, including the SAS transport file import: require (foreign) require (chron) require (Hmisc) require (lattice) clin <- sasxport.get("y:\\temp\\subset.xpt") attach(clin)