Skip to content

Commit 7da49b4

Browse files
committed
docs: update primary instruction to install radian
1 parent 8bf27a6 commit 7da49b4

File tree

3 files changed

+32
-44
lines changed

3 files changed

+32
-44
lines changed

CHANGELOG.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## Unreleased
4+
5+
### Documentation
6+
7+
* docs: update primary instruction to install radian
8+
39
## 0.6.14 - 2025-05-04
410

511
### Bug Fixes
@@ -1301,10 +1307,6 @@
13011307

13021308
## 0.0.40 - 2017-12-30
13031309

1304-
### Documentation
1305-
1306-
* doc the settings
1307-
13081310
### Other
13091311

13101312
* new option for not inserting new line
@@ -1315,6 +1317,7 @@
13151317
* update insert auto match filters
13161318
* only R args in Nvim-R
13171319
* remote note to reticulate
1320+
* doc the settings
13181321
* remove the note for bracketed paste mode
13191322
* restrict the auto match scope
13201323
* update prompt toolkit code

README.md

Lines changed: 23 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,22 @@
66
[![Conda version](https://img.shields.io/conda/vn/conda-forge/radian.svg)](https://anaconda.org/conda-forge/radian)
77
<a href="https://www.paypal.me/randy3k/5usd" title="Donate to this project using Paypal"><img src="https://img.shields.io/badge/paypal-donate-blue.svg" /></a>
88

9-
109
<img src="radian.png"></img>
1110

1211
_radian_ is an alternative console for the R program with multiline editing and rich syntax highlight.
1312
One would consider _radian_ as a [ipython](https://github.com/ipython/ipython) clone for R, though its design is more aligned to [julia](https://julialang.org).
1413

1514
<img width="600px" src="https://user-images.githubusercontent.com/1690993/30728530-b5e9eb5c-9f26-11e7-8453-73a2e880c9de.png"></img>
1615

17-
1816
## Features
1917

2018
- cross platform, runs on Windows, macOS and Linux
2119
- shell mode: hit `;` to enter and `<backspace>` to leave
2220
- reticulate python repl mode: hit `~` to enter
2321
- improved R prompt and reticulate python prompt
24-
- multiline editing
25-
- syntax highlight
26-
- auto completion (reticulate autocompletion depends on `jedi`)
22+
- multiline editing
23+
- syntax highlight
24+
- auto completion (reticulate autocompletion depends on `jedi`)
2725
- unicode support
2826
- latex completion
2927
- auto matching parens/quotes.
@@ -32,44 +30,34 @@ One would consider _radian_ as a [ipython](https://github.com/ipython/ipython) c
3230
- automatically adjust to terminal width
3331
- read more than 4096 bytes per line
3432

35-
3633
## Installation
3734

3835
Requirements:
3936

40-
- An installation of R (version 3.4.0 or above) is required to use _radian_, an R installation binary for your system can be downloaded from https://cran.r-project.org.
41-
- `python` (version 3.7 or above) is also required to install _radian_. If your system doesn't come with a python distribution, it can be downloaded from https://www.python.org/downloads/ or https://conda.io/en/latest/miniconda.html.
42-
- `pip` is optional but it makes the installation a bit easier.
37+
- An installation of R (version 3.4.0 or above) is required to use _radian_, an R installation binary for your system can be downloaded from <https://cran.r-project.org>.
38+
- `python` (version 3.8 or above) is also required to install _radian_. If your system doesn't come with a python distribution, it can be downloaded from <https://www.python.org/downloads/>.
39+
- Installing `radian` via [`pipx`](https://pipx.pypa.io/stable/installation/) would be the easiest option.
4340

4441
```sh
4542
# install released version
46-
pip3 install -U radian
43+
pipx install radian
44+
# or the dev version
45+
pipx install git+https://github.com/randy3k/radian
4746
# to run radian
4847
radian
4948
```
5049

51-
```sh
52-
# or the development version
53-
pip3 install -U git+https://github.com/randy3k/radian
54-
```
55-
56-
Alternatively, if you use conda or miniconda,
57-
```sh
58-
conda install -c conda-forge radian
59-
```
60-
In this case, it is recommended to install R via conda to ensure consistency in C runtime libraries.
61-
6250
## Alias on unix system
6351

6452
You could alias `r` to _radian_ by putting
6553

6654
```bash
6755
alias r="radian"
6856
```
57+
6958
in `~/.bash_profile` such that `r` would open _radian_ and `R` would still open the traditional R console.
7059
(`R` is still useful, e.g, running `R CMD BUILD`.)
7160

72-
7361
## Settings
7462

7563
_radian_ can be customized by specifying the below options in various locations
@@ -81,12 +69,11 @@ _radian_ can be customized by specifying the below options in various locations
8169
- `.radian_profile` in the working directory
8270

8371
The options could be also specified in the `.Rprofile` files, however,
84-
it is not recommended because
72+
it is not recommended because
8573

8674
1. the settings are not persistent when vanilla mode is used;
8775
2. it doesn't work well with `packrat` or `renv`.
8876

89-
9077
```r
9178
# Do not copy the whole configuration, just specify what you need!
9279
# see https://pygments.org/styles
@@ -182,40 +169,39 @@ options(
182169

183170
## FAQ
184171

185-
#### Unicode doesn't work in Windows and R 4.2+.
186-
187-
The latest version of R supports Unicode codepage directly. However, radian relies on Python and Python doesn't support Unicode in the way that R supports it. A workaround could be found here: https://github.com/randy3k/radian/issues/269#issuecomment-1169663251. Though it may break the ploting device (running `plot()` will kill radian).
172+
#### Unicode doesn't work in Windows and R 4.2+
188173

174+
The latest version of R supports Unicode codepage directly. However, radian relies on Python and Python doesn't support Unicode in the way that R supports it. A workaround could be found here: <https://github.com/randy3k/radian/issues/269#issuecomment-1169663251>. Though it may break the ploting device (running `plot()` will kill radian).
189175

190-
#### I can't specify python runtime in reticulate.
176+
#### I can't specify python runtime in reticulate
191177

192-
It is expected. `radian` runs on python and the python runtime used by radian is forced in
178+
It is expected. `radian` runs on python and the python runtime used by radian is forced in
193179
reticulate. `reticulate::py_config()` gives the note:
180+
194181
```
195182
NOTE: Python version was forced by the current process
196183
```
197184

198185
In order to use radian with another python runtime, you will need to install `radian` on
199186
that python environment.
200187

201-
202-
#### How to switch to a different R or specify the version of R.
188+
#### How to switch to a different R or specify the version of R
203189

204190
There are serveral options.
205191

206192
- The easiest option is to pass the path to the R binary with `--r-binary`, i.e., `radian --r-binary=/path/to/R`
207193
- Also, one could expose the path to the R binary in the `PATH` variable
208194
- The environment variable `R_BINARY` could also be used to specify the path to R.
209195
- The environment variable `R_HOME` could also be used to specify R home directory. Note that it is should be set as the result of `R.home()`, not the directory where `R` is located. For example, in Unix
196+
210197
```sh
211-
$ env R_HOME=/usr/local/lib/R radian
198+
env R_HOME=/usr/local/lib/R radian
212199
```
213200

214201
#### Cannot find shared library
215202

216203
Please also make sure that R was installed with the R shared library `libR.so` or `libR.dylib` or `libR.dll`. On Linux, the configure flag `./configure --enable-R-shlib` may be needed to install R from the source. Do not forget to `make clean` to force the recompilation of the files with the correct compiler options.
217204

218-
219205
#### Outdated setuptools
220206

221207
If you encounter
@@ -229,30 +215,29 @@ pip install -U setuptools
229215
230216
```
231217

232-
233218
#### How to use local history file
234219

235220
_radian_ maintains its own history file `.radian_history` and doesn't use the `.Rhistory` file. A local `.radian_history` is used if it is found in the launch directory. Otherwise, the global history file `~/.radian_history` would be used. To override the default behavior, you could launch _radian_ with the options: `radian --local-history`, `radian --global-history` or `radian --no-history`.
236221

237-
238222
#### Does it slow down my R program?
239223

240-
_radian_ only provides a frontend to the R program, the actual running eventloop is the same as that of the traditional R console. There is no performance sacrifice (or gain) while using this modern command line interface.
224+
_radian_ only provides a frontend to the R program, the actual running eventloop is the same as that of the traditional R console. There is no performance sacrifice (or gain) while using this modern command line interface.
241225

242226
However, it was reported that radian may be slower when using parallel computation, specifially when using forking. User should take extra care in those cases.
243227

244228
#### Nvim-R support
245229

246230
Put
231+
247232
```vim
248233
let R_app = "radian"
249234
let R_cmd = "R"
250235
let R_hl_term = 0
251236
let R_args = [] " if you had set any
252237
let R_bracketed_paste = 1
253238
```
254-
in your vim config.
255239

240+
in your vim config.
256241

257242
#### `reticulate` Auto Completions
258243

@@ -263,11 +248,11 @@ pip install jedi
263248
```
264249

265250
Alternatively, if you use conda,
251+
266252
```sh
267253
conda install -c conda-forge jedi
268254
```
269255

270-
271256
#### Prompt not shown inside a docker container
272257

273258
It maybe caused by the invalid terminal size, try running `stty size` in your terminal

cliff.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ postprocessors = []
5050
conventional_commits = false
5151
commit_parsers = [
5252
{ message = "^[f|F]eat[ :]", group = "Features" },
53-
{ message = "^[f|F]ix[ :]", group = "Bug Fixes" },
54-
{ message = "^[d|D]oc[ :]", group = "Documentation" },
53+
{ message = "^(?i)fix[ :]", group = "Bug Fixes" },
54+
{ message = "^[d|D]ocs[ :]", group = "Documentation" },
5555
{ message = "^[p|P]erf[ :]", group = "Performance" },
5656
{ message = "^[r|R]efactor[ :]", group = "Refactor" },
5757
{ message = "^[s|S]tyle[ :]", group = "Styling" },

0 commit comments

Comments
 (0)