<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 RiiDataFrame
Here, a little bit more detail about RiiDataFrame class will be given.
Step1:  RiiDataFrame has an attribute named catalog that is a Pandas DataFrame provinding the catalog of experimental data as shown below.
The columns formula and tabulated indicate the type of data. If n or k is included in the column tamulated, the experimentally observed refractive index n or extinction coefficient k is  given in tabulated form, respectively. If tabulated is f, only coefficients of formula are given. 
On the other hand, the number written in the column formula indicates the number of dispetsion formula that fits the experimental data. If the number is 0, only the tabulated data are given.
Step2:  The experimental data are given by raw_data
Step3:  where n is the refractive index and k is the extinction coefficient at the vacuum wavelength wl_n (wl_k) in the unit of &mu;m.
The column c gives the coefficients for the dielectric function model.
In the above example, no coefficient is given because only the tabulated data are given (formula number in catalog is 0).
On the other hand, if formula number is not 0, some coefficeints are given in the column c as shown below.
In this case, formula 21 means Drude-Lorentz model, which is explained in Dispersion formulas.
Step4:  Using the method load_grid_data(), you can get grid data calculated at 200 wavelength values in the range [wl_min, wl_max], which is the intersection between the domain of n [wl_n_min, wl_n_max] and the domain of k [wl_k_min, wl_k_max]. These values are shown in catalog.
Step5:  Helper Methods
By using the functionality of Pandas, you may find what you want, easily. But, here some simple helper methods are implemented.
plot
plot(id
Step6:  search
search(name
Step7:  select
select(condition
Step8:  show
show(id
Step9:  read
read(id, as_dict=False)
This method returns the contants of a page associated with the id.
If you want the page contents as a python dict, give True for argument as_dict.
Step10:  references
references(id
Step11:  material
material(params
<ASSISTANT_TASK:>
Python Code:
import riip
ri = riip.RiiDataFrame()
Explanation: RiiDataFrame
Here, a little bit more detail about RiiDataFrame class will be given.
End of explanation
ri.catalog.head(3)
Explanation: RiiDataFrame has an attribute named catalog that is a Pandas DataFrame provinding the catalog of experimental data as shown below.
The columns formula and tabulated indicate the type of data. If n or k is included in the column tamulated, the experimentally observed refractive index n or extinction coefficient k is  given in tabulated form, respectively. If tabulated is f, only coefficients of formula are given. 
On the other hand, the number written in the column formula indicates the number of dispetsion formula that fits the experimental data. If the number is 0, only the tabulated data are given.
End of explanation
ri.raw_data.loc[3].head(5)  # first 5 rows for the material whose id is 3
Explanation: The experimental data are given by raw_data:
End of explanation
ri.catalog.tail(3)
ri.raw_data.loc[2911].head(5)  # first 5 rows for the material whose id is 2912
Explanation: where n is the refractive index and k is the extinction coefficient at the vacuum wavelength wl_n (wl_k) in the unit of &mu;m.
The column c gives the coefficients for the dielectric function model.
In the above example, no coefficient is given because only the tabulated data are given (formula number in catalog is 0).
On the other hand, if formula number is not 0, some coefficeints are given in the column c as shown below.
In this case, formula 21 means Drude-Lorentz model, which is explained in Dispersion formulas.
End of explanation
grid_data = ri.load_grid_data(3)
grid_data
Explanation: Using the method load_grid_data(), you can get grid data calculated at 200 wavelength values in the range [wl_min, wl_max], which is the intersection between the domain of n [wl_n_min, wl_n_max] and the domain of k [wl_k_min, wl_k_max]. These values are shown in catalog.
End of explanation
import matplotlib.pyplot as plt
ri.plot(3, "n")
plt.show()
ri.plot(3, "k")
plt.show()
ri.plot(3, "eps")
plt.show()
Explanation: Helper Methods
By using the functionality of Pandas, you may find what you want, easily. But, here some simple helper methods are implemented.
plot
plot(id: int, comp: str = "n", fmt1: Optional[str] = "-", fmt2: Optional[str] = "--", **kwargs)
* id (int): ID number.
* comp (str): 'n', 'k' or 'eps'.
* fmt1 (Union[str, None]): Plot format for n and Re(eps).
* fmt2 (Union[str, None]): Plot format for k and Im(eps).
Plot refractive index (if set comp="n"), extinction coefficient (comp="k") or permittivity (comp="eps").
End of explanation
ri.search("NaCl")
ri.search("sodium") # upper or lower case is not significant
Explanation: search
search(name: str) -&gt; DataFrame
This method searches data whose book or book_name contain given name and return a simplified catalog for them.
End of explanation
ri.select("2.5 < n < 3 and 0.4 < wl < 0.8").head(10)
ri.plot(157)
Explanation: select
select(condition: str) -&gt; DataFrame
This method make a query with the given condition and return a simplified catalog. It will pick up materials whose experimental data contains some data that fulfill given condition.
End of explanation
ri.show(1)
Explanation: show
show(id: int | Sequence[int]) -&gt; DataFrame
This method shows a simplified catalog for given id.
End of explanation
print(ri.read(0))
ri.read(0, as_dict=True)
Explanation: read
read(id, as_dict=False)
This method returns the contants of a page associated with the id.
If you want the page contents as a python dict, give True for argument as_dict.
End of explanation
ri.references(20)
Explanation: references
references(id: int)
This method returns the REFERENCES of a page associated with the id.
End of explanation
water = ri.material({'id': 428})
water.catalog
Explanation: material
material(params: dict) -&gt; Material
Create Material-class instance for given parameter dict params.
params can includes the following parameters,
* 'id': ID number. (int)
* 'book': book value in catalog of RiiDataFrame. (str)
* 'page': page value in catalog of RiiDataFrame. (str)
* 'RI': Constant refractive index. (complex)
* 'e': Constant permittivity. (complex)
* 'bound_check': True if bound check should be done. Defaults to True. (bool)
* 'im_factor': A magnification factor multiplied to the imaginary part of permittivity. Defaults to 1.0. (float)
End of explanation
<END_TASK>