我正在尝试使用rsDriver函数运行RSelenium,但是当我运行时,出现
rD <- rsDriver()
一条消息告诉我我需要更新版本的Chrome:
> rD <- rsDriver()
checking Selenium Server versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking chromedriver versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking geckodriver versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking phantomjs versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
[1] "Connecting to remote server"
Selenium message:session not created: This version of ChromeDriver only supports Chrome version 74
(Driver info: chromedriver=74.0.3729.6 (255758eccf3d244491b8a1317aa76e1ce10d57e9-refs/branch-heads/3729@{#29}),platform=Mac OS X 10.14.3 x86_64)
Could not open chrome browser.
Client error message: …Run Code Online (Sandbox Code Playgroud) 我知道 savefig 有一个选项 dpi。但如果我用plotly 绘图并写入图像,我就没有设置dpi 的选项。
如何用plotly设置dpi?
TypeError: write_image() got an unexpected keyword argument 'dpi'
Run Code Online (Sandbox Code Playgroud) cairosvg 的命令行版本允许缩放。这是帮助函数的输出:
cairosvg -h
usage: cairosvg [-h] [-v] [-f {pdf,png,ps,svg}] [-d DPI] [-W WIDTH]
[-H HEIGHT] [-s SCALE] [-u] [-o OUTPUT]
input
CairoSVG - A simple SVG converter based on Cairo.
positional arguments:
input input filename or URL
optional arguments:
-h, --help show this help message and exit
-v, --version show program\'s version number and exit
-f {pdf,png,ps,svg}, --format {pdf,png,ps,svg}
output format
-d DPI, --dpi DPI ratio between 1 inch and 1 pixel
-W WIDTH, --width WIDTH
width of the …Run Code Online (Sandbox Code Playgroud)