Page 1 of 15 12311 ... LastLast
Results 1 to 10 of 148

Thread: Vim R plugin installation issue

  1. #1
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    417
    Distro
    Ubuntu 10.04 Lucid Lynx

    Vim R plugin installation issue [SOLVED]

    I am attempting to install the vim R plugin on Hardy, and am rather confused. I am not sure whether I have installed the plugin but can't figure out how to use it, or if it isn't installed at all.

    I have:
    - Installed R from the Ubuntu repositories
    - Installed gVim using Synaptic
    - added Johannes Ranke's Debian sid repository (deb http://www.uft.uni-bremen.de/chemie/ranke/debs sid-jr/) to my /etc/apt/sources.list
    - sudo apt-get update
    - sudo apt-get install vim-r-plugin

    Installation of the plugin seemed to go fine. However I don't see any option for it in vim. When in vim I:
    - Change filetype to r (:set ft=r)
    - Press F2. This should bring up a console running R, in theory. But the computer just beeps at me, and nothing happens.

    More information on this plugin may be found at:
    http://www.vim.org/scripts/script.php?script_id=1048
    http://www.uft.uni-bremen.de/chemie/...ge=vim_R_linux

    Do I just not understand how to use the plugin? Or has it not installed correctly? If anyone can offer any advice I would be most grateful. I am a complete novice on vim by the way, this is the first time I have used it.
    Last edited by samden; May 1st, 2008 at 03:36 AM. Reason: Solved
    IBM ThinkCentre 8142 - Ubuntu 10.04
    Acer emachines D620 - Ubuntu 9.04

  2. #2
    Join Date
    Dec 2007
    Beans
    23

    Re: Vim R plugin installation issue

    I've also struggled with installing vim plugins. I noticed this section under "install details" on the first page:
    Note that you have to activate addons like this plugin since vim version
    7.1-022+1, July 2007. For system-wide activation, use

    $ vim-addons -w install r-plugin

    (details in README.Debian).
    Have you tried that? As an alternative, you might try downloading the archive on that page and extracting it to ~/.vim/plugins.

  3. #3
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    417
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Vim R plugin installation issue

    Ok, that fixed it. Just made myself look a bit stupid there, didn't read the instructions properly!

    Thanks heaps.
    IBM ThinkCentre 8142 - Ubuntu 10.04
    Acer emachines D620 - Ubuntu 9.04

  4. #4
    Join Date
    Dec 2007
    Location
    Ireland
    Beans
    102
    Distro
    Ubuntu Development Release

    Re: Vim R plugin installation issue

    Samden,

    I see you got it fixed up
    Good work. I had the same problem after upgrading to Hardy on laptop: ie the F2 key would no longer load an xterm with R running. Re-installing plugin with the system wide thing above got it fixed.

    Easy now...
    Linux user #460711
    Ubuntu user number #20615

  5. #5
    Join Date
    Nov 2007
    Beans
    14

    Thumbs down Re: Vim R plugin installation issue

    Sorry - i don't know wether I should start a new thred, as this is already marked as 'solved'? Anyways - here goes:
    When I:
    Code:
    vim-addons -w install r-plugin
    I get
    Info: ignoring 'r-plugin' which is neither removed nor broken
    Then in Vim (or gvim - tried both) I press F2 - nothing happens... Any ideas?

    Intripid

  6. #6
    Join Date
    Nov 2007
    Beans
    14

    Re: Vim R plugin installation issue

    If I open an r. script, go to visual-mode (v) and select some r-code and then press "r" i get this error message: "~/.r-pipe" E212: Can't open file for writing

    Hope somebody can help

  7. #7
    Join Date
    Nov 2006
    Beans
    7

    Re: Vim R plugin installation issue

    Same problem here. The plugin appears to be installed properly, except when I hit <F2> an xterm window opens and then immediately closes.

  8. #8
    Join Date
    May 2007
    Beans
    17

    Re: Vim R plugin installation issue

    Instructions didn't quite work for me on gutsy or intrepid.

    I used the etch-jr archive (deb http://www.uft.uni-bremen.de/chemie/ranke/debs etch-jr/ ), all goes fine. When i run "vim-addons -w install r-plugin" i get the following:

    Warning: Ignoring unknown addons: r-plugin

    I can copy or link the files manually from
    /usr/share/vim/addons/ftplugin/
    to ~/.vim, and then everything works very well. I edited r.vim to open gnome-terminal, which has a slightly different syntax...

    ***-T becomes -t, -e becomes -x

    "Start a listening R interpreter in new xterm
    noremap <buffer> <F2> :!gnome-terminal -t 'R' -x funnel.pl ~/.r-pipe "R && echo -e 'Interpreter has finished. Exiting. Goodbye.\n'"&<CR><CR>

    incidentally, my system-wide install of syntax/r.vim wasn't working from a previous .vim/filetype.vim entry, causing great confusion. I had to change
    au! BufNewFile,BufRead *.r,*.R setfiletype R
    to
    au! BufNewFile,BufRead *.r,*.R setfiletype r

    hope this helps.
    Last edited by helmingstay; April 21st, 2009 at 04:33 AM.

  9. #9
    Join Date
    Sep 2007
    Location
    Brazil
    Beans
    77

    Re: Vim R plugin installation issue

    I'm developing a new plugin based on the work of Johannes Ranke. The plugin allows the user to kill R from vim. It also has omni completion of R objects and correct indentation of R code.

    I think people reading this thread may be interested in testing the plugin and reporting bugs. The plugin is here: http://www.vim.org/scripts/script.php?script_id=2628

    Last edited by jalvesaq; May 16th, 2009 at 07:27 PM. Reason: Updated link to vim-rplugin2

  10. #10
    Join Date
    Nov 2007
    Beans
    15

    Re: Vim R plugin installation issue

    I'm testing it. Glad someone keeps on developing that script.

Page 1 of 15 12311 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •