similar to: Expression in legend of plot

Displaying 20 results from an estimated 20000 matches similar to: "Expression in legend of plot"

2007 Jun 08
2
legend + expression
Dear all; A simple? question. I'm having a problem with a math expression in the legend of a plot and I haven't found the way to get this to work, so any help will be appreciate. Basically I want to include in the plot is the R-squared and its numerical value, so I tried this: R2c<-0.82879 # R-squared of calibration model plot(1:10,1:10) legend("topleft",
2013 Jan 23
1
italic font for legend text when using expression function for symbols
Hello, I'm trying to add a symbol (Delta) to plot legend with text using "expression(paste())" but this disables the text.font that allows to use bold or italic text. as follows: x=c(1:10) y=c(1:10) plot(x,y) legend(1,10,legend=c("A","B","C",expression(paste(Delta, D))), pch=c(24,18,17,16),cex=2,text.font=3,bty="n") Any suggestion to
2002 Mar 12
1
mathematical expression in legend
Hello, I'm trying to put a mathematical expression into a legend, but R complains about a syntax error. Basically i'd like to do this: legend.text = c(expression(x < 10), expression(x >= 10)) The manual says that one can only pass mathematical expressions to axis, text etc. but not to the legend command? Is there a workaround for this? thanks a lot for help, Arne -- Arne
2004 Apr 27
1
legend(1,1,expression(a<-"10^-6"))
hi all, I have a problem with showing properly formated mathematical expressions in a plot. The following works: plot(1:10) legend(1,10, expression(10^-6)) Howver, if my expression is kept in a char variable, I don't know how to show it in the legend. # I have st_"10^-6" # I try to do this plot(1:10) legend(1,10, expression(st)) # which doesn't turn out as expected Is it
2005 Jun 01
1
"\n" in legend using substitute and as.expression
Dear R users, Is it possible to force a hard return in an expression. I tried including one for a legend using an expression and it didn't work. Here is my code, legend(12, 0.10, c("Fitted density", as.expression(substitute(paste("Weibull (", alpha==shapeU," , ", beta==scaleU,") Mean = ",meanU," days"), list(shapeU =
2012 May 08
4
Axes value format
Hi all, I have some graphs where the values on the X and Y axes are by default in exponent form like 2e+05 or 1.0e+07. Is it possible to make them in a more readable form like 10M for 1.0e+07 or 200K for 2e+05? Thanks and Regards, - vihan
2014 Mar 18
1
Developing the UPS side of the UPS-NUT equation (via usbhid)
Things are going along well, but there is one remaining area of confusion...."units". I understand exponents now...it's basically how you pass decimal values. That's easy enough. But "units"....in other words, I have a voltage I want to put in a report. If I include in the report descriptor the fact that it is actually a voltage, with units of "volts",
2013 Feb 04
2
Contract Syntactic Sugar
## the following is a dream: add some sugar syntax to allow for contracts with teeth (in and out checking) > is.positive <- function(x) (all(x>0)) > exponentiate <- function( x ::is.data.frame , exponent ::is.numeric is.positive) :: is.vector is.numeric { x$base :: is.positive ## error also if base does not exist in x; may need some special IQ x$base^exponent }
2012 Jul 30
1
lattice legen and auto.key conflict
Hello R-helpers, I'm trying to customize a graphic in lattice using the 'legend' argument to add labels on my plot but in the process I'm losing the legend drawn by 'auto.key', despite the fact that I'm actually not sticking these on the same sides of the graphic. I worked up a quick and simple example with the iris data : ### here's the basic graph
2011 Sep 24
1
ggplot2: expression() in legend labels?
Is there any way to use expression() in legend labels with ggplot2? It seems that things like > scale_shape_manual(value = c( > x = expression(italic(x)), > y = expression(italic(y)) > )) don't work. Thanks very much :) -- Using GPG/PGP? Please get my current public key (ID: 0xAEF6A134, valid from 2010 to 2013) from a key server. -------------- next part --------------
2012 Jun 22
2
Boxplot with Log10 and base-exponent axis
Dear all, I would like to (i) produce boxplot graphs with axis in logarithm in base 10 and (ii) showing the values on the axis in 10^exponent format rather than 10E+exponent. To illustrate with an example, I have some widely spread data that I chart plot using boxplot() [figure on the left]; the log="y" option of boxplot() I obtained the natural logarithm conversion of the data and
2009 May 15
1
Matrix package,solve() errors and crashes Please help
> > Hello All, > Please help me with this problem.I have been having this problem for over a month now and I could not find any information.I later realised that error is with MATRIX package. I am working on graph object using IGRAPH version 0.5.2-2 package & wanted to do Bonacich Power. What I have is undirected GRAPH. This is my graph object. The file 'Bonacich
2011 Aug 10
1
Floats in Microsoft Basic format
Hi all, I need to convert a floating point value from Microsoft Basic format to IEEE format. There's a simple way to achieve this in R or I have to write my own function? (e.g. convert the C code below) thanks t #include <string.h> /* for strncpy */ int _fmsbintoieee(float *src4, float *dest4) { unsigned char *msbin = (unsigned char *)src4; unsigned char *ieee
2012 May 07
1
Value of Hurst exponent (R/S) method > 1
Hello, I'm using fArma package to estimate the value of Hurst exponent using R/S method. However, for a certain set of data I get H ~ 1.8. How do I interpret this? Following are the output that I get for this set: > mean(data[,2]) [1] 400.5433 > sd(data[,2]) [1] 1139.786 > > rsFit(data[,2], levels = 64) Title: Hurst Exponent from R/S Method Call: rsFit(x = data[, 2], levels
2003 Jun 20
1
Power Law Exponents
I am having difficulty with the calculation of the power law exponent for set of nodes within a graph. Specifically, I am interested in the distribution of in-degree and out-degree among communities of web pages where the web pages are the nodes of the graph and the hyperlinks the edges. According to the literature, the distribution of incoming and outgoing links obeys a power law distribution
2012 May 31
2
time-series statistics collection
Hello, I am trying to collect several global measures or statistics for time-series as well as packages of R that can compute them. I have found several of them in papers and books, but the literature is so big i am sure i am missing several of them. skewness kurtosis min max mean SD trend seasonality periodicity chaos (Lyapunov Exponent) / Largest Lyapunov Exponent (i think is the same
2023 Oct 30
1
Missing shapes in legend with scale_shape_manual
Hello, I'm trying to plot a graph of blood glucose versus date. I also record conditions, such as missing the previous night's medications, and missing exercise on the previous day. My data looks like: > b2[68:74,] # A tibble: 7 ? 5 Date Time bg missed_meds no_exercise <date> <time> <dbl> <lgl> <lgl> 1 2023-10-17 08:50
2010 Jul 11
1
difficulty with R expressions in text/legend
hi, i'm trying to prepend some plain (i.e. unevalutated) text to a typographically evaluated R expression in a legend(...) call. here's a working legend(...) call that is close to what i'd like (where x and y are returned from an lm(...) call): legend("topleft", legend = c(bquote(R^2 == .(summary(x)$r.squared)), bquote(R^2 == .(summary(y)$r.squared))), fill =
2004 Jul 27
2
Incorrect display of b[hat((a))] expression in plots
Hi, I am not sure if this is a bug or a non-implement feature of text-drawing functions with TeX-style expression, but hat() and some of its equals does not get the right "bounding boxes" if they are put in sub- or superscripts. For instance, for the expression 'b[hat(a)]' the hat() seems to shift 'hat(a)' too much to the right of 'b'. Try the below example and
2018 May 23
3
Change the legend order by order function
Hi, I'd like to graph three lines on ggplot2 and I intend the lines to be "solid", "dashed", and "dotted". The legend names are "name_b", "name_c", "name_a". I'd like to legend to present in the order: the "name_b" at the top, and "name_a" at the bottom. Could it be done by order function or its inverse?