R Projects

Similar to Python, when we installed the data science tools we get an “R” section in our templates. If you go there you’ll see something like this:

Only one template to choose from, but that’s ok! That is all we need.

R Interactive

Just like there’s a Python Interactive, there’s also an R Interactive window. It acts very similar to the Python Interactive, as well. Just highlight or put your cursor on the line in a script you want to send to the interactive and hit Ctrl+Enter. Of course, you can just type directly into the interactive to get some quick result or feedback on a piece of code. Oh, and there is syntax highlighting and intellisense right in the interactive!

Running R Code

Like all applications in Visual Studio, just hitting the green “Run” button will execute your code. And, just like with Python, you can set a breakpoint in your R code and debug through it.

Visualizations

Having R support in Visual Studio wouldn’t be useful if it didn’t support visualizations. Similar to RStudio, Visual Studio has a tab that’s used to display plots.

Luckily, R comes provided with quite a few sample data sets. To list them all just type in data(). Let’s look at a dataset called JohnsonJohnson, which is quarterly earning of Johnson & Johnson from around 1960 to 1980. Let’s use a scatterplot that also adds a curve.

scatter.smooth(JohnsonJohnson)

Pretty nice for just a small line of code! You can imagine how much more complicated the visualizations can get just by adding a bit more code.

R Markdown

R has a really nice feature to help distribution code, text, and visualizations with R Markdown. Pretty similar to Python’s Jupyter Notebooks, it also features a way to output to different formats, such as PDF and HTML. Visual Studio also has support for this, though it takes a little bit to set up. Microsoft has a nice documentation page that details all that you need to do. Now you can create R Markdown files in Visual Studio!

While you can output your R Markdown document in HTML, PDF, and Word, RStudio has a few more ways you can. It allows you to also output as an actual web site or a scientific article. Hopefully, Visual Studio can provide most of the other output types fairly soon.

Shiny Apps

One of the things I have a hard time trying to find are ways to deploy your models. Sure you can have everything local, but what’s good about that if no one else can see or use it? Well, the same team who brought us RStudio also has a very compelling feature for R to share your findings – Shiny. This framework allows you to create web applications to share your findings and, even better, to share your models for anyone to interact with. They also supply hosting for your web applications, so they have all that you need to get your findings and models out to the world.

Unfortunately, Visual Studio doesn’t support Shiny. Although, I really hope they will integrate better support for Azure in order to deploy web services that will call into our models and host web applications that use those web services.

转载于:https://www.cnblogs.com/Javi/p/7047444.html

Data Science With R In Visual Studio相关推荐

  1. Visual Studio 2005中编译调试新功能

    在日常的编程中,程序员经常离不开的工作之一,就是调试.当写好一段代码或程序后,在运行后总会出现这样那样的问题,比如各样的错误,程序员就必须进行调试,将这些错误排除.在最新出炉的Visual Studi ...

  2. Visual Studio 2017全面上市

    自从1997年第一版发布的20年以来,微软Visual Studio开发工具一向以易学易用.功能齐全而闻名,帮助开发者以简驭繁,即使面对越来越快速的交付压力,也能大幅提高生产力,好整以暇.对于Visu ...

  3. 使用SQL Server数据工具和Visual Studio Online进行连续部署

    In the previous posts 在以前的帖子中 Deployment to several databases using SQL Server Data Tools and TFS us ...

  4. 微软:Visual Studio 2017是迄今为止最高效的版本

    自从 1997 年第一版发布的 20 年以来,微软 Visual Studio 开发工具一向以易学易用.功能齐全而闻名,帮助开发者以简驭繁,即使面对越来越快速的交付压力,也能大幅提高生产力,好整以暇. ...

  5. 新工具︱微软Microsoft Visual Studio的R语言模块下载试用Ing...(尝鲜)

    笔者:前几天看到了以下的图片,着实一惊.作为R语言入门小菜鸟,还是觉得很好看,于是花了一点时间下载下来试用了一下,觉得还是挺高大上的. 就是英文不好是硬伤.下面贴给小白,我当时的下载步骤与遇见的问题. ...

  6. C#笔记24:善用Visual Studio

    C#笔记24:善用Visual Studio 1:调试的四个窗口 2:加快编码速度 3:加快编码速度 4:使用第三方工具丰富VS 5:VS2010中的工具 6:学会调试 1:调试的四个窗口 立即窗口: ...

  7. Visual Studio 的键盘快捷方式

    全局 分析 命令 键盘快捷键 分析.向后定位 Shift+Alt+3 分析.向前定位 Shift+Alt+4 体系结构 命令 键盘快捷键 体系结构.新建关系图 Ctrl+\.Ctrl+N 生成 命令 ...

  8. Visual Studio 2017 新功能(下)

    调试和诊断 运行时单击 只需在调试运行到此行时单击代码行旁边的图标. 无需再设置临时断点,也不必再执行多个步骤来执行代码和在所需行停止. 现在,调试器下停在中断状态时,"运行时单击" ...

  9. Visual Studio 2017 新功能(上)

    开发:快速导航.编写并修复代码 新的安装体验 - 降低了最小内存需求量以实现更快.更定制化的安装,并且支持脱机安装. Visual Studio IDE - 大幅改进了 Visual Studio 2 ...

  10. Visual Studio 2017 RC3支持.NET Core,延迟对Python的支持

    Visual Studio 2017第三个候选版本上周发布,解决了之前发现的安装程序的小问题.由于这些问题得到了解决,现在值得关注的就是这次版本中更新了什么内容.(版本是发布于1月27日的build ...

最新文章

  1. 机器学习基础专题:随机变量
  2. vue一二级联动清空二级数据_【周一实用技巧】二级联动还不够,自动更新才最牛。Excel 2013利用数据验证条件制作一级、二级联动和自动更新下拉列表...
  3. 【Android 应用开发】Google 官方 EasyPermissions 权限申请库 ( 最简单用法 | 一行代码搞定权限申请 | 推荐用法 )
  4. 实例讲解js中的预编译
  5. mysqldump 导出某几张表
  6. 农保和社保的区别有哪些
  7. 转载: 关于显著性检验,你想要的都在这儿了!!(基础篇)
  8. Git安装Windows / Redhat / Ubuntu
  9. 身价超13000亿!他又重回世界首富了
  10. php生成GIF动态验证码图片(代码家园)
  11. 【车间调度】基于matlab模拟退火算法求解车间调度(jobshop-3)问题【含Matlab源码 1082期】
  12. 一种数字全息散斑干涉测量仿真模拟系统
  13. 百旺智能编码_百旺税控盘如何增加商品编码?
  14. java银行叫号课程设计_课程设计-银行排队叫号机设计.doc
  15. 全球新能源500强四季沐歌借助氚云搭建业务系统,实现人效翻倍!
  16. 实现Excel下拉自动填补对应内容到后面单元格
  17. linux18.04 英文文件夹,在Ubuntu 18.04 LTS中打开文件夹的6种方法
  18. 编程语言评价标准:冯诺伊曼体系
  19. 2022第十二届中国电子文件管理论坛嘉宾揭晓
  20. 五分钟看懂python函数(同Java方法作比较)

热门文章

  1. 学历真的改变能命运? | 数据告诉你
  2. R|ggplot2(七)|自定义主题
  3. JS 输入框智能提示
  4. SPASVO推出ALM(覆盖全生命周期的研发过程管理平台)免费在线体验平台
  5. cf12E Start of the season(构造,,,)
  6. Sql Server 时间格式
  7. 写一个程序,打印数字1到100,3的倍数打印“Fizz”来替换这个数,5的倍数打印“Buzz”,对于既是3的倍数又是5的倍数的数字打印“FizzBuzz”...
  8. 比较好的文章地址收集
  9. SpringMVC是单例的
  10. TypeScript手册翻译系列1-基础类型