All Questions
1 question
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
2
answers
48
views
How to transform the data with id and count into one column? [duplicate]
My data is
ID n
1 3
2 2
3 4
I want it to be like
ID
1
1
1
2
2
3
3
3
3
The only way I can solve it is that I use for loop.
Below is my code
y <- read.csv('Desktop/勞研所/20220831 攜出/py.csv')
data ...
This tag is in a collective: a subcommunity defined by tags with relevant content and experts.
- The Overflow Blog
-
-
- Featured on Meta
-
-
-
-
-
Related Tags
reshape × 1
Hot Network Questions
- OTA took our money but won't give confirmation for my flight until 24 hrs before
- What are the Rhine Experiments, Their Purpose, and Significance?
- Is the complexity of using \lua_now:e justified when debugging complex expl3 code
- Using standard AC fixtures for DC applications
- Discrepancy in Limit calculation: Sum of limit vs limit of sum
- Protecting Secrets in Lost F/A-18 Super Hornet
- How could technological development be significantly accelerated without a major war?
- Dostoevsky on Tyutchev
- My work is being read but not used — what can I improve?
- Smallest possible pentomino farm
- Rounding Float Values in ML Models
- Why do we multiply by 2 in a two-tailed test when the test statistic’s distribution is not symmetric?
- Why is nord-est pronounced \nɔ.ʁ‿ɛst\ ?
- Can a darkmantle willingly detach?
- Combining vs. Separating Predictors: What’s Better for Prediction
- Why Linux read() avoids using full 2 GiB in one call
- How to compute an error estimate with an ESDIRK Runge-Kutta method that contains a (singular) mass matrix?
- Retrieving connected components from list of neighbors
- What is the difference between a minority government and a coalition government?
- How is this navigation radio for the 737 operated?
- In light cone, why is it a cone and not a sphere, given that light travels in all directions in space-time? Is it a projection of slice of 4D sphere?
- Movie where a dying man creates a machine that creates alternate realities
- Plot two fuctions and the region between them: Axis labels at wrong position
- Do limits leave residual infinitesimals, or do they resolve exactly?