Standard Java library
The standard Java library is very rich and offers a lot of tools for data manipulation, including:
- Collections for organizing data in memory
- I/O for reading and writing data
- Streaming APIs for making data transformations easy
In this chapter, we will look at all these tools in detail.Â
Collections
Data is the most important part of data science. When dealing with data, it needs to be efficiently stored and processed, and for this we use data structures. A data structure describes a way to store data efficiently to solve a specific problem, and the Java Collection API is the standard Java API for data structures. This API offers a wide variety of implementations that are useful in practical data science applications.
We will not describe the collection API in full detail, but concentrate on the most useful and important ones--list, set, and map interfaces.
Lists are collections where each element can be accessed by its index. The g0-to implementation of the List
interface is...