I want to add a new value to the first column and first row of the data frame.
Sample of data:
ali ata
1 u w
2 y e
3 t r
4 f x
5 s z
Expected Results:
ali ata
1 ttt NA
2 u w
3 y e
4 t r
5 f x
6 s z
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Read the data. Here, it’s important to encode strings as strings (not as factors):
You could use
rbindto add the value: