I am working on a real time application which is recording sensor data continuously. I need to process the data in realtime using R. Is there a way to connect and communicate with the uno board through RStudio via serial port?
If RStudio has serial support. Yes, it can talk to a Uno. If it does not. No.
This is really a question about RStudio (and actually just pure R), not arduinos.
Furthermore, RStudio is just an IDE. Therefore, no, RStudio can not communicate with an arduino, compile a program, or do much of all aside from edit source-code files. RStudio does not run your code at all. It uses an external interpreter to run your source files.
R, on the other hand probably can talk to serial interfaces. The fact that you're using RStudio is entirely irrelevant.
I'm not familliar with R, but a little googling leads me to think that R can talk to serial interfaces without too much trouble, though I have not been able to find any information about doing so on windows. What platform are you using?
I can't seem to figure out directly how to read from a serial port using R; While there does seem to have been at least one attempt to provide this, it's not clear that it ever graduated to something supported or easily installable.