I have a dataframe as below. I am trying to check if there is a `nan` in the `Liq_Factor`, if yes, put 1 otherwise divide `use/TW`. Result in column Testing.

```
+---+------------+------------+--------+--------+--------+
| 1 |            | Liq_Factor | Zscire | Use    | Tw     |
| 2 | 01/10/2020 | 36.5       | 44     | 43.875 | 11.625 |
| 3 | 02/10/2020 | Nan        | 43.625 | 13.625 | 33.25  |
| 4 | 03/10/2020 | 6.125      | 47.875 | 22.5   | 4.625  |
| 5 | 04/10/2020 | Nan        | 34.25  | 37.125 | 36     |
| 6 | 05/10/2020 | 43.875     | 17.375 | 5.5    | 36.25  |
| 7 | 06/10/2020 | 40         | 14.125 | 21.125 | 14.875 |
| 8 | 07/10/2020 | 42.25      | 44.75  | 21.25  | 31.75  |
+---+------------+------------+--------+--------+--------+

```

I was wondering if i can use `.apply` in the sense of

```
DF1['Testing']=(DF1['Liq_Factor'].apply(lambda x: x=1 if pd.isna(DF1['Zscore']) else DF1['Use']/DF1['Tw'])

```

Can you please help?

Thanks,
H