Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Q2. R coding I need help coding this in R. The data was uploaded like this: d1 = read.csv(C:UsersPamDocumentsUTSASemester 3DA6233tech_financials.csv, header=TRUE) d2 0) Print a

Q2. R coding

I need help coding this in R. The data was uploaded like this:

d1 = read.csv("C:\\Users\\Pam\\Documents\\UTSA\\Semester 3\\DA6233\\tech_financials.csv", header=TRUE)

d2 <- filter(d1, sale > 0)

Print a data frame with the means of sale, oibdp, and xrd for Apple, Meta, and Tesla. For this, you will need to follow these steps:

a) Filter only the observations pertaining to Apple, Meta, and Tesla

b) Group by conm

c) Summarize sale, oibdp, and xrd to get their means you may optionally use across() inside summarize(). This function will save you writing more code. Read more about it here: https: //dplyr.tidyverse.org/reference/across.html

d) Output it as a data frame by using as.data.frame() function.

Thank you!

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

A First Course In Differential Equations With Modeling Applications

Authors: Dennis G Zill

11th Edition

1337515574, 9781337515573

More Books

Students also viewed these Mathematics questions