R-studio might not support your R-version. In that case the R-studio graphics device does not work and it uses the default device from R which results in a new window. However, this is usually accompanied with a warning message when starting R telling you this. So, you might want to update R-studio. HTH, Jan