You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
3.**Bonus question:** Extract the rows from `rpkm_ordered` that correspond to these 6 genes using `[]`, but without using the `isin` operator.
64
+
3.**Bonus question:** Extract the rows from `rpkm_ordered` that correspond to these 6 genes using `[]`, but without using the `isin` operator. Do you notice anything different about the output?
65
65
66
66
```{python}
67
67
#| label: exercise_3
68
68
# Extract rows for important genes without using isin operator
69
69
rpkm_ordered.loc[important_genes]
70
70
```
71
71
72
+
The rows are now in the order that we specified the genes of interest. When we used `isin` above, we got the rows in the order that they are present in the expression data.
10. In the `data` directory, you should have a dataframe called `proj_summary` which contains quality metric information for an RNA-seq dataset. We have obtained batch information for the control samples in this dataset. **Copy and paste the code below to create a dataframe of control samples with the associated batch information**:
171
+
10. In the `data` directory, you should have a table called `project-summary.txt` that contains quality metric information for an RNA-seq dataset. We have obtained batch information for the control samples in this dataset. **Copy and paste the code below to create DataFrames for the project summary and for the control samples with the associated batch information**:
12. Keep only the rows in `proj_summary` which correspond to those in `ctrl_samples`. Do this with the `isin` operator. Save it to a variable called `proj_summary_ctrl`.
0 commit comments