Creating an executable R-file - r

I want to make an executable R-file (for automation purposes). Therefore I concluded the following tutorial.
After completion however nothing happens... Only the .Rexec file opening in RStudio (in stead of running it and showing me the pop up...
Any more people experienced this? Any clues to where to look to fix this?

The tutorial you gave is useful. However, it missed something.
After done all the things in that blog, you still need to do one more thing. Right click on the "test.Rexec" file and choose "open with" and then select "RScript". Maybe you need to find RScript in your system which is usually here:
C:\Program Files\R\R-3.2.1\bin\Rscript.exe
Remeber to check the "Always use the selected program to open this kind of file".
Next time, when you double click the "test.Rexec" file, evethying would be okay.

I found no need to create Rexec file.
I created .bat file and then set it up in Task Scheduler.
The .bat file opens up the Rscript.exe, as shown in prev answer above. The .bat file then points to the .R file, that I want to be executed.
For some time, I could not get it to work, but solution was to point to Rscript.exe as mentioned above. Then it will not open up in compiler.
Works fine for me.

Related

Debug certain lines in RTVS (R Tools for Visual Studio)

Currently the only way to debug in RTVS is to first attach the debugger and then source the file, as shown in this official manual. However, this is rather inconvenient, since my script usually expands to hundreds of lines and it will take forever for the debugger to execute to the breakpoint, which usually at the last of the script.
The only workaround I can come up with now is to comment all the above lines before the codes of interests. But, is there any elegant way to achieve that?
So far there is no shortcut for it yet, to debug the certain line in R, we still have to launch the debugger with the code in script.R by either selecting the Source startup file button on the toolbar, selecting the Debug > Source startup file menu items, or pressing F5. Visual Studio enters its debugging mode and starts running the code. It stops on the line where you set the breakpoint:
https://learn.microsoft.com/en-us/visualstudio/rtvs/getting-started-with-r#debugging-your-code

Iexpress.exe Unable to open report file even when ran as administrator

I'm creating a Iexpress package, and no matter what on the final step it pops up the message "Unable to open report file" and stops. I am searching Iexpress.exe and right clicking, then choosing "Run As Administrator" to start it. The problem persists.
I had this error running as my account (domain admin) not specifically telling it to run as administrator, removed spaces then re-ran working fine under Windows 10 1809 you shouldn't need to change to a different application to create .EXE files using IEXPRESS this is working fine under Window 10.
The way to fix this problem:
Go to the folder where your files you want to be in the package are
Go to the top bar (Where it says where you are on your drive), and type iexpress
Do the creation as normal, but the names you give the installer shouldn't have any spaces.
I did it this way without admin permissions.
I ended up moving on to Inno Setup Compiler. Turns out Iexpress isn't supported anymore. I recommend Inno to anyone making their own programs.
This happens when SourceFilesX or TargetName paths in the directive (i.e. the files you've added from the wizard) contain spaces. And while the issue with the TargetName can be fixed with adding double quotes the only workaround I've found about the source files is to put them in a folder path that not contains spaces.

.R files not opening suddenly on anaconda

I use Anaconda for both python and R, I updated today, after that none of my R files are opening. I wrote a block of code, saved and tried to open, but after it opens, the entire file is empty.
I tried uninstalling and installing again, but its the same. Can anyone help me out with this please, my college project work is struck in between and I see all my developed codes gone suddenly.
Thank You in Advance
I’ve had this happen to me a few times. My work around is the navigate to the file in file explorer, right click on it, and open in a text editor. This should provide you your code. From there copy and paste back into your IDE. Further, saving the file with UTF-8 encoding supposedly helps as well, but I have yet to determine if this is a full workaround.

Ada 2012 and the GNAT GPS IDE Debugger Can't Find Source File

I'm working with a simple hello world single .adb file program in Ada 2012 using the GPS IDE under Windows 7/64. If I keep all the object and source files together everything works. I did have to go to the project properties Switches tab and select the Ada tab and enable the 'Debug Information' checkbox.
Now I want to organize my project a little better and put the object files in their own directory. I used the project properties Objects tab and changed the setting from . to ojb. I can build and run. Now when I go to debug and click on a line in hello.adb I get the "No source file named hello.adb. I'm guessing that it's looking in the obj directory. I tried issuing a set directory command and gave the absolute path to the parent folder. A subsequent show directories command shows that the folder containing my hello.adb file is now in the path but still no joy. I can no longer set a breakpoint. This doesn't seem like that unusual an operation, I suspect there is another higher level way to specify the source path for the debugger. Anyone know what it is, or any tips on getting this to work?
GPS itself does not do the debugging. It spawns a command line debugger named gdb for that purpose. You could try running GPS with --traceon=GVD.OUT (or alternatively, and often simpler on Windows, change the %USERPROFILE%.gps\traces.cfg file and add "GVD.OUT=yes").
This will log all communications between GPS and gdb in %USERPROFILE%.gps\log.*, which might be helpful in understanding why gdb is not outputting the correct full path for the files.
Please also double-check that "-g" is indeed passed to the compiler (perhaps after removing all files from obj)

XCode open file at error line for custom build script

I Apologize if this question has already been asked. i can't seem to find it anywhere if it has.
I have a custom build script use to syntax check some php files and upload them to a server, and this is executed as a part of the build process. since this script is used to parse inline php statements (embedded in objective c blocks using macros) it's fairly critical this script happens on each build. the actual execution is working fine, i'd just also like to be able to open a particular file when there is an error, and locate the cursor in the approximate location.
i have found that since xcode is configured on my system to open .php files by default (not sure if that's the norm or if i did it manually at some point), using
open filename.php
in a shell script opens the file.
i'd like to be able to specify the line number too.
eg something along the lines of
open filename.php --args --jump-to-line 1234
(--args is a switch for "open" meaning pass the arguments on to Xcode)
any ideas?
You can use the xed command. Only works for Xcode 3 though, not other editors. For Xcode 4, try this
See man xed

Resources