Is there any way of runnning a line of code in octave without highlighting it?

67 views Asked by At

In Rstudio you can run the code of the current line by pressing Ctrl+Enter. In octave (I'm using 8.3.0) you can do something similar by highlighting the text and then press F9, but is there a way to do this in a single button instead of having to reach my mouse or use other shortcut keys to highlight the text first?

1

There are 1 answers

0
Nick J On

Unfortunately Octave does not have this feature. As you said, you can run a highlighted code block using F9. If you are currently in debug mode, you can run the current line of code that you are paused on with the F10 key (or use the Step button or menu option). But there is no current method to just run the full line of code at the current cursor location in the editor window, which I believe is the feature you're requesting. This would be an interesting feature that some might find valuable in their workflows. Identifying a key or key combination that wouldn't collide with other functions might require some thought. Perhaps CTRL-F9 or similar would work. I would encourage you to create a Feature Request report over at bugs.octave.org. It might not be a high priority request, but if it gains enough interest there's a possibility someone would pick it up to implement. If you do so, please link back the bug report to this question.