课程: R for Data Science: Lunch Break Lessons

免费学习该课程!

今天就开通帐号,24,100 门业界名师课程任您挑!

Use the Matrix package

Use the Matrix package

- [Narrator] We've spoken quite a bit about matrices and the tools that are provided to manipulate them. What we haven't spoken about is the matrix package and the matrix package is part of R, but it's not loaded. Let's take a look first of all, at what a recommended packages. I can list them with installed.packages with priority equal recommended. I'll scroll to the top of this list and you can see in the left hand side, there's a boot and class and cluster and code tools. These are all recommended, but not loaded. We want to load the matrix package. To do that, I'll use library with matrix now notice that I'm using capital matrix, not lowercase matrix. Now when I hit run or return, nothing happens but it happens behind the scenes. The matrix package has been loaded in and this available free me to use. Let's take a look at the difference between a sparse matrix as provided by the matrix package and the dense matrix…

内容