I'm just starting to learn R and getting to know all the functionalities and shortcuts. I know that both <- and = can be used as an assignment operator in most contexts, but my question is: when I try the shortcut alt + - I always get = in the R Notebook, even though I'd rather use <-. Is there a way I can change my default operator? In the console it works fine, the issue is just in the notebook.
I'm using Windows 10 and a Portuguese keyboard (POR/PTB). Also tried Portuguese/International (POR/INTL) and it makes no difference.
Until I switched over to using Linux for most of my work, I hadn't noticed this, because on my macOS I had a keyboard macro long installed to simply expand my abbreviations. And I was puzzled, as you are, why it works differently in the editor and console.
I was looking for somewhere to edit this and thought that the Global Options | Code | Snippets might provide a way, but no luck. Try typing
> fun
in the console and waiting for the autocomplete suggestions, and see that it doesn't work in the editor.
When I add the same fun snippet from the console on the Mardown snippets, it actually works. So what you're saying is that there's no way I can change my default operator from = to <- in the editor?