This is an update.

Next Update

Final Update

Try executing this chunk by clicking the Run button within the chunk or by placing your cursor inside it and pressing Ctrl+Shift+Enter.

This is an example of code.

x= 10
y= 5

Add a new chunk by clicking the Insert Chunk button on the toolbar or by pressing Ctrl+Alt+I.

When you save the notebook, an HTML file containing the code and output will be saved alongside it (click the Preview button or press Ctrl+Shift+K to preview the HTML file).

The preview shows you a rendered HTML copy of the contents of the editor. Consequently, unlike Knit, Preview does not run any R code chunks. Instead, the output of the chunk when it was last run in the editor is displayed.

Rprogramming Basics

variables

x-y
[1] 5
x+y
[1] 15
abc = 100
a = 10
b = 5
#char_variable
s1 = "This is a string"

#Boolean_variable

a = TRUE
b = FALSE
LS0tDQp0aXRsZTogIlNodXZvaml0IERhcyINCm91dHB1dDogaHRtbF9ub3RlYm9vaw0KLS0tDQoNClRoaXMgaXMgYW4gdXBkYXRlLg0KDQpOZXh0IFVwZGF0ZQ0KDQpGaW5hbCBVcGRhdGUNCg0KVHJ5IGV4ZWN1dGluZyB0aGlzIGNodW5rIGJ5IGNsaWNraW5nIHRoZSAqUnVuKiBidXR0b24gd2l0aGluIHRoZSBjaHVuayBvciBieSBwbGFjaW5nIHlvdXIgY3Vyc29yIGluc2lkZSBpdCBhbmQgcHJlc3NpbmcgKkN0cmwrU2hpZnQrRW50ZXIqLiANCg0KYGBge3J9DQpgYGANCg0KVGhpcyBpcyBhbiBleGFtcGxlIG9mIGNvZGUuDQoNCmBgYHtyfQ0KeD0gMTANCnk9IDUNCg0KYGBgDQoNCmBgYHtyfQ0KDQpgYGANCg0KDQoNCg0KQWRkIGEgbmV3IGNodW5rIGJ5IGNsaWNraW5nIHRoZSAqSW5zZXJ0IENodW5rKiBidXR0b24gb24gdGhlIHRvb2xiYXIgb3IgYnkgcHJlc3NpbmcgKkN0cmwrQWx0K0kqLg0KDQpXaGVuIHlvdSBzYXZlIHRoZSBub3RlYm9vaywgYW4gSFRNTCBmaWxlIGNvbnRhaW5pbmcgdGhlIGNvZGUgYW5kIG91dHB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