'proj' object in the Quick Tutorial #1015
-
Hi, I am reading the quick tutorial, https://www.archrproject.com/articles/Articles/tutorial.html, and following the code. As I am a beginner, I am confused in several lines. In the beginnig, I made 'proj' object by 'ArchRProject' function
Then, I filter out doublects by 'filterDoublets' function. Then, it gets the output to 'proj' object, which is the same as ArchRProject. This makes me confused when I run the down streams.
Next step is dimensionality reduction.
In 'addIterativeLSI', ArchRProj=proj will be from 'proj' by filterDoublets if I want to use 'proj' after filtering doublets, am I correct? I was confused because many functions, such as ArchRProject, filterDoublets, addIterativeLSI, addClusters.. and others in the downstream are getting the output to the same object name 'proj.' When I ran the code first time, I input 'proj' that I got in the just above function. After reading the code lines again, I think I was wrong. The input 'proj' is from 'ArchRProject or 'filterDoublets.' Could you tell me if I understood correctly? Thank you, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
This is very typical of the The return value of most functions in ArchR is an ArchRProject object. So you pass your current project to the function, it effectively creates a copy of that object while it performs operations, and then it returns the updated object which we use to overwrite the original object. |
Beta Was this translation helpful? Give feedback.
This is very typical of the
R
programming language and is a bit counterintuitive for people coming from different languages.The return value of most functions in ArchR is an ArchRProject object.
So you pass your current project to the function, it effectively creates a copy of that object while it performs operations, and then it returns the updated object which we use to overwrite the original object.