|
556 | 556 | "cell_type": "markdown", |
557 | 557 | "metadata": {}, |
558 | 558 | "source": [ |
559 | | - "> **NOTE**: most positions are NaN when the timestamp is from background.\n", |
| 559 | + "> **NOTE**: positions are NaN when the timestamp is from background.\n", |
560 | 560 | "\n", |
561 | 561 | "Check that we have NaNs if and only if the timestamp is from background:" |
562 | 562 | ] |
|
693 | 693 | "metadata": {}, |
694 | 694 | "outputs": [], |
695 | 695 | "source": [ |
696 | | - "fig, ax = plt.subplots(figsize=(2, 5))\n", |
697 | | - "ax.plot(R, Z, 'o', alpha=0.1)\n", |
698 | | - "ax.set_xlim(0, 1)\n", |
699 | | - "ax.set_ylim(-2, 2)\n", |
700 | | - "ax.set(xlabel='R (μm)', ylabel='Z (μm)');" |
| 696 | + "# Increase the resolution of the figures displayed in the notebook\n", |
| 697 | + "%config InlineBackend.figure_format = 'retina' # 'png' for default res" |
| 698 | + ] |
| 699 | + }, |
| 700 | + { |
| 701 | + "cell_type": "code", |
| 702 | + "execution_count": null, |
| 703 | + "metadata": {}, |
| 704 | + "outputs": [], |
| 705 | + "source": [ |
| 706 | + "psf = pbm.NumericPSF().hdata\n", |
| 707 | + "cmap = plt.cm.YlGnBu\n", |
| 708 | + "cmap.set_under(alpha=0)\n", |
| 709 | + "kwargs = dict(interpolation='bicubic', origin='lower', cmap=cmap, vmin=1e-1, zorder=1)\n", |
| 710 | + "\n", |
| 711 | + "fig, ax = plt.subplots(figsize=(8, 2))\n", |
| 712 | + "ax.imshow(psf.T, extent=(-6, 6, 0, 4), **kwargs)\n", |
| 713 | + "ax.plot(Z, R, '.', ms=5, color='C1', alpha=0.3)\n", |
| 714 | + "ax.set(ylabel='R (μm)', xlabel='Z (μm)', ylim=(0, 1), xlim=(-2, 2));" |
701 | 715 | ] |
702 | 716 | }, |
703 | 717 | { |
|
733 | 747 | "sideBar": true, |
734 | 748 | "skip_h1_title": false, |
735 | 749 | "toc_cell": false, |
736 | | - "toc_position": {}, |
| 750 | + "toc_position": { |
| 751 | + "height": "591.867px", |
| 752 | + "left": "0px", |
| 753 | + "right": "959px", |
| 754 | + "top": "111.133px", |
| 755 | + "width": "212px" |
| 756 | + }, |
737 | 757 | "toc_section_display": "block", |
738 | 758 | "toc_window_display": false |
739 | 759 | } |
|
0 commit comments