SCM

Forum: open-discussion

Monitor Forum | Start New Thread Start New Thread
RE: How to use logical & and | in RGG [ Reply ]
By: ilhami visne on 2009-02-28 22:21
[forum:1296]
Hello,

The .rgg files are XML files and the & is a special character (http://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references).

The solution: if(a & b)

And some other examples:
- if(a < b) ==> if(a &lt; b)
- if(a > b) ==> if(a &gt; b)

Or assuming you have a big chunk of R code, then you can write them(actually anything) between <![CDATA[ and ]]>

example:
<![CDATA[
hh <- t(VADeaths)[, 5:1]
mybarcol <- "gray20"
mp <- barplot(hh, beside = TRUE,
col = c("lightblue", "mistyrose",
"lightcyan", "lavender"),
legend = colnames(VADeaths), ylim= c(0,100),
main = "Death Rates in Virginia", font.main = 4,
sub = "Faked upper 2*sigma error bars", col.sub = mybarcol,
cex.names = 1.5)
]]>

i hope this helps,
ilhami

How to use logical & and | in RGG [ Reply ]
By: Thomas Latzko on 2009-02-26 20:44
[forum:1281]
Hallo everybody,
every time i want to use the logical "and" operator like "if(a & b)" i get an GUI-error. Has anybody a solution?
best regards


Thanks to:
Vienna University of Economics and Business Powered By FusionForge