I have the following data.frame, called tableMS:
X Y Z T
1 375 855 455.7259 3777.856
2 395 969 347.8306 2506.7
3 449 811 309.9512 519.8513
4 451 774 278.291 717.8705
5 453 774 278.291 717.8705
6 455 774 278.291 717.8705
7 521 697 376.734 693.8541
8 529 855 455.7259 3777.856
9 531 855 455.7259 3777.856
10 609 774 278.291 717.8705
when I try to use the function melt()
MeltTable <- melt(tableMS,id=c("X","Y"))
I get the following error:
Error in match.names(clabs, names(xi)) :
names do not match previous names
I struggle to understand what happens, any idea?
Edit: I generated tableMS as portion of a bigger table and the output of str(tableMS) is:
'data.frame': 10 obs. of 4 variables:
$ X: num 375 395 449 451 453 455 521 529 531 609
$ Y: num 855 969 811 774 774 774 697 855 855 774
$ Z:List of 10
..$ : num 456
..$ : num 348
..$ : num 310
..$ : num 278
..$ : num 278
..$ : num 278
..$ : num 377
..$ : num 456
..$ : num 456
..$ : num 278
$ T:List of 10
..$ : num 3778
..$ : num 2507
..$ : num 520
..$ : num 718
..$ : num 718
..$ : num 718
..$ : num 694
..$ : num 3778
..$ : num 3778
..$ : num 718