Question in R Language

I'm trying to use R to create a new dynamic pivot table.

dt <- [url removed, login to view](TableIn)

PivotTable1 <- dcast(dt, A + B + C + D ~E, [url removed, login to view] = "F")

PivotTable <- PivotTable1[c("B","P",“C”,"A","G")]

From this function, I'm able to create a new dynamic pivot table.

Right now, I would like to set a order on this new table likes third function above.

But issue is that I'm not able to set order for columns newly generated from dcast function such as G & P.

For example, we can generate columns "B",“C”,"G","A" under case 1 while generating columns "B",“C”,"P","A", under case 2. Then it shows me error message. Because case 1 doesn't include column "P". However, we set a order for column "P" in third function.

Right now, I need a function which is able to generate all columns by particular order. If some columns are not available in some inputs, other columns are still supposed to be in order.

Skills: R Programming Language

See more: r programming questions and answers pdf, r interview questions for data scientist, r coding questions, r interview questions listen data, r statistics interview questions, r questions and answers, multiple choice questions in r programming, r programming exam questions, I\ m starting a construction company and I would like to create a logo for The Company name is C&A , and it has a saying : empre, I\ m trying to do data entry, r language, r language freelancer com, r language freelance, looking for a 2d animator to create an approximately 60 second end credit sequence for a short film i m looking for a similar st, i m looking for a sport shoe designer to create a new product for me company in thailand that could make different sports clothi

About the Employer:
( 2 reviews ) Piscataway, United States

Project ID: #15339772

6 freelancers are bidding on average $44 for this job


Experienced R programmer with more than 4 years of experience as a Developer and Analyst. Relevant Skills and Experience Proficient with packages like [url removed, login to view], dplyr, tidyr etc. for data preparation and pre-process More

$30 USD in 1 day
(7 Reviews)

Hi I am a very experienced statistician and academic writer. I have completed several PhD level thesis projects involving advanced statistical analysis of data. I have worked with data from several companies and have d More

$100 USD in 1 day
(5 Reviews)

A proposal has not yet been provided

$50 USD in 2 days
(3 Reviews)

About me: Graduated from statistic department in faculty of economic & politic science, Cairo University. Sub-specialized in social science computing Cum. Grade: Good Graduation project grade: Excellent. How can I More

$30 USD in 2 days
(1 Review)
$25 USD in 1 day
(1 Review)

Hey i am 3 years experienced in Machine Learning ,R  and python.i had done many projects in machine learning such as: Stock Market prediction system in R Disease Prediction system OCR system Fault Detection system More

$30 USD in 2 days
(0 Reviews)