程序问答   发布时间:2022-06-01  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了R 错误:尝试使用零长度变量名大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。

如何解决R 错误:尝试使用零长度变量名?

开发过程中遇到R 错误:尝试使用零长度变量名的问题如何解决?下面主要结合日常开发的经验,给出你关于R 错误:尝试使用零长度变量名的解决方法建议,希望对你解决R 错误:尝试使用零长度变量名有所启发或帮助;

我使用的是 R 编程语言。我正在学习使用著名的 iris 数据集制作交互式仪表板的教程:https://beta.rstudioconnect.com/jjallaire/htmlwidgets-rbokeh-iris/htmlwidgets-rbokeh-iris.html

我复制并粘贴了源代码(在安装了必要的库之后):

---
Title: "rbokeh iris dataset"
author: "Ryan Hafen"
output: 
  flexdashboard::flex_dashboard:
    orIEntation: columns
    social: menu
    source_code: embed
---

```{r setup,include=FALSE}
library(rbokeh)
library(flexdashboard)
```

Column {data-wIDth=600}
-----------------------------------------------------------------------

### SpecIEs

```{r}
figure(wIDth = NulL,height = NulL) %>%
  ly_points(Sepal.Length,Sepal.WIDth,data = iris,color = SpecIEs)
# figure() %>%
#   ly_points(Sepal.Length,#     color = SpecIEs,glyph = SpecIEs)
```


Column {data-wIDth=400}
-----------------------------------------------------------------------

### SpecIEs (Quantile)

```{r}
figure(wIDth = NulL,height = NulL,legend_location = "top_left") %>%
  ly_quantile(Sepal.Length,group = SpecIEs,data = iris)
```

### Petal WIDth

```{r}
figure(wIDth = NulL,color = Petal.WIDth)
```

这产生了很多错误:

> Column {data-wIDth=600}
Error: unexpected '{' in "Column {"
> -----------------------------------------------------------------------
+     
+     ### SpecIEs
+     
+     ```{r}
Error: attempt to use zero-length variable name
> figure(wIDth = NulL,height = NulL) %>%
+     ly_points(Sepal.Length,color = SpecIEs)
> # figure() %>%
> #   ly_points(Sepal.Length,> #     color = SpecIEs,glyph = SpecIEs)
> ```
Error: attempt to use zero-length variable name
> 
> 
> Column {data-wIDth=400}
Error: unexpected '{' in "Column {"
> -----------------------------------------------------------------------
+     
+     ### SpecIEs (Quantile)
+     
+     ```{r}
Error: attempt to use zero-length variable name
> figure(wIDth = NulL,legend_location = "top_left") %>%
+     ly_quantile(Sepal.Length,data = iris)
> ```
Error: attempt to use zero-length variable name
> 
> ### Petal WIDth
> 
> ```{r}
Error: attempt to use zero-length variable name
> figure(wIDth = NulL,+               color = Petal.WIDth)
> ```
Error: attempt to use zero-length variable name

这会单独生成所有图,例如:

R 错误:尝试使用零长度变量名

但它不会产生从网站产生的“交互式仪表板”。有人可以告诉我我做错了什么吗?

谢谢

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

大佬总结

以上是大佬教程为你收集整理的R 错误:尝试使用零长度变量名全部内容,希望文章能够帮你解决R 错误:尝试使用零长度变量名所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。
标签: