如何使用“R图形生成器”和“R Graphics”使用StatEt Eclipse插件查看? [英] How to use "R Graph Builder" and "R Graphics" view with StatEt Eclipse Plugin?

查看:190
本文介绍了如何使用“R图形生成器”和“R Graphics”使用StatEt Eclipse插件查看?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是R新手,想在Windows 7上使用Oxygen.2 Release(4.7.2)的Eclipse插件StatEt。



我尝试创建一个使用R Graph Builder绘制示例图。我点击播放按钮,然后在 R代码选项卡上获得以下输出。此外,我听到ping的声音。

  library(ggplot2)

p < - ggplot (数据= mtcars,aes(x = mpg,y = cyl))
p <-p + labs(title =test)

print(p)

但是,我看不到任何图表。

=> play action的目的只是为了产生控制台输出吗?





=>我可以在哪里找到有关图形编辑器的文档?

=>可以输入什么数据来获取第一个示例图? / p>

此外,当我在StatEt中绘制图形时,我希望其输出处于R图形视图中。但是,R打开了一个新窗口。在我的控制台运行配置中的R控制台选项卡上启用了选项通过StatET将R图形视图设置为R中新图形的默认图形设备。

=>R图形视图的目的是什么?



示例图:

  x <-c(1:10 )
y <-sin(x)
plot(x = x,y = y)




$ pre $ library $ g $ p $ b $ ggplot(data = mtcars,aes(x = wt) )+ geom_bar()

相关问题:




  • 创建图形后,示例代码将以代码形式编写。这通常发送到R控制台。您现在应该能够在R Graphics视图中看到图形结果。




    I am new to R and want to use the Eclipse plugin StatEt with Oxygen.2 Release (4.7.2) on Windows 7.

    I tried to create an example plot with the R Graph Builder. I click the "play button" and get following output on the R Code tab. Furthermore, I hear a "ping" sound.

    library(ggplot2)
    
    p <- ggplot(data = mtcars, aes(x = mpg, y = cyl))
    p <- p + labs(title = "test")
    
    print(p)
    

    However, I can not see any graph.

    => Is the purpose of the "play action" only to produce the console output?

    => Where can I find documentation about the Graph Builder?

    => What data can I enter to get a first example graph?

    Furthermore, when I plot a graph in StatEt, I would expect its output to be in the view "R Graphics". However, a new window is opened by R. I have the option "Set R Graphic view by StatET as default graphic device for new plots in R" enabled on the tab "R Console" in my console run configuration.

    => What is the purpose of the "R Graphics" view?

    Example plots:

    x<-c(1:10)
    y<-sin(x)       
    plot(x=x,y=y)
    

    -

    library(ggplot2)
    ggplot(data = mtcars,aes(x=wt))+geom_bar()
    

    Related questions:

    解决方案

    • In order to use those features of StatEt you need to select RJ (default) instead of Rterm in the Console run configuration. (Rterm might be useful for trouble shooting and initial setup but RJ is required for normal usage. The R package RJ needs to be installed from within R. Apply Rterm once for doing so or use R.exe directly. Also see ClassNotFoundException for StatEt Eclipse plugin / RJ. Compatibility issue with Java9?)

    • RJ 2.1 is not compatible to Java 9. Currently you need to install Java8 and select it in the JRE settings of the run configuration.

    • Make sure that the box Set R Graphic view by StatET as default graphic device for new plots in R is checked in Run configuration>R console. (It is checked by default.)

    Once you have created your graph, the example code is written in code. This is normally sent to the R console. You should now be able to see the graphical result in the R Graphics view.

    这篇关于如何使用“R图形生成器”和“R Graphics”使用StatEt Eclipse插件查看?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆