Read in the same hsv_2020_climo_data.csv file into Pandas DataFrame with the Date column as the index (similar to examples before).
Answer the following questions with formatted print statements.
What are the data types of each column? (i.e. 'MaxTemperature' dtype is int64)
What is the highest maximum temperature for the entire year?
What is the lowest minimum temperature for the entire year?
How much total rain did we get for 2020? (Hint you will need to handle the "Trace" values first)
Make a plot with Maximum Temperature, Minimum Temperature, and Average Temperature with labels and title.
Data below
Date MaxTemperature MinTemperature AvgTemperature Precipitation Snowfall SnowDepth
2020-01-01 53 31 42.0 0.00 0.0 0
2020-01-02 54 45 49.5 3.42 0.0 0
2020-01-03 59 53 56.0 0.32 0.0 0
2020-01-04 56 31 43.5 0.08 0.0 0
2020-01-05 55 29 42.0 0.00 0.0 0
2020-01-06 60 35 47.5 0.03 0.0 0
2020-01-07 55 35 45.0 T 0.0 0
2020-01-08 61 30 45.5 0.00 0.0 0
2020-01-09 60 36 48.0 0.00 0.0 0
2020-01-10 65 58 61.5 T 0.0 0
2020-01-11 72 50 61.0 1.08 0.0 0
2020-01-12 59 46 52.5 0.00 0.0 0
2020-01-13 62 43 52.5 0.08 0.0 0
2020-01-14 64 60 62.0 0.96 0.0 0
2020-01-15 67 60 63.5 0.61 0.0 0
2020-01-16 60 42 51.0 0.03 0.0 0
2020-01-17 59 40 49.5 0.00 0.0 0
2020-01-18 57 45 51.0 0.17 0.0 0
2020-01-19 45 27 36.0 0.00 0.0 0
2020-01-20 28 22 25.0 T T 0
2020-01-21 37 23 30.0 0.00 0.0 0
2020-01-22 46 20 33.0 0.00 0.0 0
2020-01-23 47 39 43.0 0.72 0.0 0
2020-01-24 54 40 47.0 0.19 0.0 0
2020-01-25 41 33 37.0 T 0.0 0
2020-01-26 49 29 39.0 0.03 0.0 0
2020-01-27 58 37 47.5 0.01 0.0 0
2020-01-28 60 31 45.5 0.00 0.0 0
2020-01-29 50 44 47.0 0.03 0.0 0
2020-01-30 60 37 48.5 0.00 0.0 0
2020-01-31 52 45 48.5 T 0.0 0
2020-02-01 50 37 43.5 0.06 0.0 0
2020-02-02 68 31 49.5 0.00 0.0 0
2020-02-03 71 40 55.5 T 0.0 0
2020-02-04 67 55 61.0 0.18 0.0 0
2020-02-05 68 62 65.0 1.16 0.0 0
2020-02-06 64 36 50.0 1.49 0.0 0
2020-02-07 41 33 37.0 T T 0
2020-02-08 53 32 42.5 0.10 T 0
2020-02-09 61 33 47.0 T 0.0 0
2020-02-10 57 49 53.0 1.78 0.0 0
2020-02-11 66 45 55.5 1.12 0.0 0
2020-02-12 70 44 57.0 1.31 0.0 0
2020-02-13 60 36 48.0 0.38 0.0 0
2020-02-14 41 26 33.5 0.00 0.0 0
2020-02-15 54 22 38.0 0.00 0.0 0
2020-02-16 58 42 50.0 0.00 0.0 0
2020-02-17 56 38 47.0 0.00 0.0 0
2020-02-18 62 46 54.0 1.32 0.0 0
2020-02-19 52 43 47.5 T 0.0 0
2020-02-20 47 33 40.0 0.85 T 0
2020-02-21 44 26 35.0 0.00 0.0 0
2020-02-22 56 24 40.0 0.00 0.0 0
2020-02-23 53 34 43.5 0.01 0.0 0
2020-02-24 55 44 49.5 0.62 0.0 0
2020-02-25 62 45 53.5 0.00 0.0 0
2020-02-26 48 36 42.0 0.04 T 0
2020-02-27 46 31 38.5 T T 0
2020-02-28 51 34 42.5 T 0.0 0
2020-02-29 55 36 45.5 0.00 0.0 0
2020-03-01 66 34 50.0 0.00 0.0 0
2020-03-02 60 52 56.0 0.44 0.0 0
2020-03-03 69 55 62.0 0.33 0.0 0
2020-03-04 60 51 55.5 0.04 0.0 0
2020-03-05 59 42 50.5 0.15 0.0 0
2020-03-06 56 37 46.5 0.00 0.0 0
2020-03-07 58 30 44.0 0.00 0.0 0
2020-03-08 65 35 50.0 0.00 0.0 0
2020-03-09 68 45 56.5 T 0.0 0
2020-03-10 70 56 63.0 0.27 0.0 0
2020-03-11 66 51 58.5 0.12 0.0 0
2020-03-12 76 57 66.5 0.26 0.0 0
2020-03-13 67 54 60.5 0.14 0.0 0
2020-03-14 74 50 62.0 0.56 0.0 0
2020-03-15 61 44 52.5 1.07 0.0 0
2020-03-16 59 44 51.5 0.02 0.0 0
2020-03-17 74 53 63.5 0.24 0.0 0
2020-03-18 77 52 64.5 0.00 0.0 0
2020-03-19 78 64 71.0 T 0.0 0
2020-03-20 72 60 66.0 1.11 0.0 0
2020-03-21 59 43 51.0 0.01 0.0 0
2020-03-22 66 43 54.5 0.07 0.0 0
2020-03-23 64 57 60.5 1.80 0.0 0
2020-03-24 76 57 66.5 2.96 0.0 0
2020-03-25 66 51 58.5 0.00 0.0 0
2020-03-26 81 47 64.0 0.00 0.0 0
2020-03-27 85 63 74.0 0.00 0.0 0
2020-03-28 82 66 74.0 0.00 0.0 0
2020-03-29 75 53 64.0 0.41 0.0 0
2020-03-30 70 52 61.0 0.02 0.0 0
2020-03-31 56 43 49.5 0.65 0.0 0
2020-04-01 62 39 50.5 0.00 0.0 0
2020-04-02 70 38 54.0 0.00 0.0 0
2020-04-03 75 42 58.5 0.00 0.0 0
2020-04-04 78 54 66.0 0.00 0.0 0
2020-04-05 81 54 67.5 0.00 0.0 0
2020-04-06 83 52 67.5 0.00 0.0 0
2020-04-07 74 62 68.0 0.00 0.0 0
2020-04-08 80 63 71.5 0.24 0.0 0
2020-04-09 71 57 64.0 0.32 0.0 0
2020-04-10 60 40 50.0 0.00 0.0 0
2020-04-11 71 37 54.0 0.00 0.0 0
2020-04-12 66 54 60.0 3.02 0.0 0
2020-04-13 66 42 54.0 T 0.0 0
2020-04-14 59 39 49.0 0.00 0.0 0
2020-04-15 61 34 47.5 0.00 0.0 0
2020-04-16 69 36 52.5 0.00 0.0 0
2020-04-17 76 45 60.5 0.07 0.0 0
2020-04-18 62 45 53.5 0.21 0.0 0
2020-04-19 63 46 54.5 1.41 0.0 0
2020-04-20 72 51 61.5 0.11 0.0 0
2020-04-21 76 50 63.0 0.00 0.0 0
2020-04-22 68 42 55.0 0.29 0.0 0
2020-04-23 70 54 62.0 0.92 0.0 0
2020-04-24 73 56 64.5 0.01 0.0 0
2020-04-25 74 53 63.5 0.21 0.0 0
2020-04-26 61 41 51.0 0.00 0.0 0
2020-04-27 72 38 55.0 0.00 0.0 0
2020-04-28 77 53 65.0 T 0.0 0
2020-04-29 72 53 62.5 0.13 0.0 0
2020-04-30 71 48 59.5 T 0.0 0
2020-05-01 76 43 59.5 0.00 0.0 0
2020-05-02 83 51 67.0 0.00 0.0 0
2020-05-03 85 58 71.5 0.00 0.0 0
2020-05-04 84 60 72.0 T 0.0 0
2020-05-05 76 56 66.0 T 0.0 0
2020-05-06 65 44 54.5 0.00 0.0 0
2020-05-07 71 39 55.0 0.00 0.0 0
2020-05-08 61 48 54.5 0.86 0.0 0
2020-05-09 64 40 52.0 0.00 0.0 0
2020-05-10 73 39 56.0 0.00 0.0 0
2020-05-11 68 43 55.5 0.00 0.0 0
2020-05-12 66 48 57.0 T 0.0 0
2020-05-13 79 55 67.0 0.05 0.0 0
2020-05-14 85 61 73.0 0.00 0.0 0
2020-05-15 84 67 75.5 0.00 0.0 0
2020-05-16 86 62 74.0 0.00 0.0 0
2020-05-17 79 65 72.0 0.23 0.0 0
2020-05-18 82 60 71.0 T 0.0 0
2020-05-19 71 54 62.5 T 0.0 0
2020-05-20 77 54 65.5 0.25 0.0 0
2020-05-21 79 57 68.0 0.00 0.0 0
2020-05-22 82 63 72.5 1.52 0.0 0
2020-05-23 86 64 75.0 0.28 0.0 0
2020-05-24 88 65 76.5 T 0.0 0
2020-05-25 88 67 77.5 0.00 0.0 0
2020-05-26 76 67 71.5 0.31 0.0 0
2020-05-27 79 61 70.0 0.74 0.0 0
2020-05-28 83 62 72.5 0.21 0.0 0
2020-05-29 83 64 73.5 0.18 0.0 0
2020-05-30 84 63 73.5 0.00 0.0 0
2020-05-31 83 59 71.0 0.00 0.0 0
2020-06-01 85 53 69.0 0.00 0.0 0
2020-06-02 89 67 78.0 0.00 0.0 0
2020-06-03 88 71 79.5 0.06 0.0 0
2020-06-04 87 68 77.5 T 0.0 0
2020-06-05 90 69 79.5 0.41 0.0 0
2020-06-06 91 68 79.5 0.00 0.0 0
2020-06-07 91 71 81.0 0.00 0.0 0
2020-06-08 84 75 79.5 0.43 0.0 0
2020-06-09 87 75 81.0 0.11 0.0 0
2020-06-10 92 65 78.5 0.00 0.0 0
2020-06-11 85 61 73.0 0.00 0.0 0
2020-06-12 88 61 74.5 0.00 0.0 0
2020-06-13 90 58 74.0 0.00 0.0 0
2020-06-14 92 62 77.0 0.00 0.0 0
2020-06-15 83 61 72.0 0.00 0.0 0
2020-06-16 81 60 70.5 0.00 0.0 0
2020-06-17 80 63 71.5 0.00 0.0 0
2020-06-18 85 61 73.0 0.00 0.0 0
2020-06-19 91 64 77.5 0.00 0.0 0
2020-06-20 94 66 80.0 0.00 0.0 0
2020-06-21 88 69 78.5 0.14 0.0 0
2020-06-22 88 68 78.0 0.14 0.0 0
2020-06-23 87 70 78.5 0.25 0.0 0
2020-06-24 75 68 71.5 0.70 0.0 0
2020-06-25 85 70 77.5 0.00 0.0 0
2020-06-26 75 68 71.5 0.15 0.0 0
2020-06-27 82 68 75.0 0.30 0.0 0
2020-06-28 90 73 81.5 0.25 0.0 0
2020-06-29 90 71 80.5 0.01 0.0 0
2020-06-30 88 70 79.0 0.84 0.0 0
2020-07-01 82 68 75.0 0.73 0.0 0
2020-07-02 89 68 78.5 0.00 0.0 0
2020-07-03 94 71 82.5 0.00 0.0 0
2020-07-04 92 71 81.5 0.00 0.0 0
2020-07-05 93 71 82.0 0.47 0.0 0
2020-07-06 88 71 79.5 0.00 0.0 0
2020-07-07 90 73 81.5 0.07 0.0 0
2020-07-08 87 73 80.0 T 0.0 0
2020-07-09 90 71 80.5 0.00 0.0 0
2020-07-10 92 73 82.5 0.00 0.0 0
2020-07-11 92 67 79.5 0.00 0.0 0
2020-07-12 82 68 75.0 1.38 0.0 0
2020-07-13 89 69 79.0 0.00 0.0 0
2020-07-14 91 70 80.5 0.00 0.0 0
2020-07-15 93 70 81.5 0.00 0.0 0
2020-07-16 91 70 80.5 0.00 0.0 0
2020-07-17 94 73 83.5 0.00 0.0 0
2020-07-18 95 73 84.0 0.00 0.0 0
2020-07-19 95 73 84.0 0.00 0.0 0
2020-07-20 95 73 84.0 0.00 0.0 0
2020-07-21 94 74 84.0 T 0.0 0
2020-07-22 92 73 82.5 0.19 0.0 0
2020-07-23 92 71 81.5 0.00 0.0 0
2020-07-24 90 73 81.5 0.00 0.0 0
2020-07-25 94 72 83.0 0.07 0.0 0
2020-07-26 94 71 82.5 0.00 0.0 0
2020-07-27 91 73 82.0 T 0.0 0
2020-07-28 90 72 81.0 T 0.0 0
2020-07-29 92 73 82.5 0.02 0.0 0
2020-07-30 90 74 82.0 0.14 0.0 0
2020-07-31 92 74 83.0 0.25 0.0 0
2020-08-01 87 70 78.5 T 0.0 0
2020-08-02 86 66 76.0 0.00 0.0 0
2020-08-03 91 67 79.0 0.00 0.0 0
2020-08-04 90 70 80.0 0.01 0.0 0
2020-08-05 92 68 80.0 0.00 0.0 0
2020-08-06 92 71 81.5 0.00 0.0 0
2020-08-07 94 69 81.5 0.00 0.0 0
2020-08-08 97 68 82.5 0.00 0.0 0
2020-08-09 96 71 83.5 0.00 0.0 0
2020-08-10 98 74 86.0 0.00 0.0 0
2020-08-11 95 73 84.0 0.49 0.0 0
2020-08-12 93 74 83.5 0.01 0.0 0
2020-08-13 94 71 82.5 T 0.0 0
2020-08-14 90 74 82.0 T 0.0 0
2020-08-15 92 71 81.5 0.00 0.0 0
2020-08-16 93 67 80.0 T 0.0 0
2020-08-17 91 67 79.0 0.00 0.0 0
2020-08-18 93 64 78.5 0.24 0.0 0
2020-08-19 91 68 79.5 1.24 0.0 0
2020-08-20 87 67 77.0 T 0.0 0
2020-08-21 82 68 75.0 0.10 0.0 0
2020-08-22 85 64 74.5 0.00 0.0 0
2020-08-23 88 68 78.0 0.00 0.0 0
2020-08-24 88 72 80.0 T 0.0 0
2020-08-25 82 72 77.0 0.15 0.0 0
2020-08-26 85 70 77.5 1.83 0.0 0
2020-08-27 91 75 83.0 0.22 0.0 0
2020-08-28 86 72 79.0 0.92 0.0 0
2020-08-29 90 74 82.0 0.02 0.0 0
2020-08-30 91 71 81.0 0.23 0.0 0
2020-08-31 87 71 79.0 0.94 0.0 0
2020-09-01 89 71 80.0 0.05 0.0 0
2020-09-02 89 74 81.5 0.00 0.0 0
2020-09-03 89 73 81.0 0.00 0.0 0
2020-09-04 90 67 78.5 T 0.0 0
2020-09-05 88 59 73.5 0.00 0.0 0
2020-09-06 86 57 71.5 0.00 0.0 0
2020-09-07 86 60 73.0 0.00 0.0 0
2020-09-08 87 64 75.5 0.00 0.0 0
2020-09-09 88 65 76.5 0.00 0.0 0
2020-09-10 90 66 78.0 0.00 0.0 0
2020-09-11 93 68 80.5 0.00 0.0 0
2020-09-12 90 73 81.5 0.01 0.0 0
2020-09-13 91 71 81.0 T 0.0 0
2020-09-14 90 69 79.5 0.00 0.0 0
2020-09-15 83 69 76.0 0.00 0.0 0
2020-09-16 74 68 71.0 0.12 0.0 0
2020-09-17 87 70 78.5 0.00 0.0 0
2020-09-18 79 61 70.0 0.00 0.0 0
2020-09-19 76 59 67.5 0.00 0.0 0
2020-09-20 81 58 69.5 0.00 0.0 0
2020-09-21 76 53 64.5 0.00 0.0 0
2020-09-22 75 51 63.0 T 0.0 0
2020-09-23 71 53 62.0 0.79 0.0 0
2020-09-24 66 55 60.5 2.65 0.0 0
2020-09-25 73 64 68.5 T 0.0 0
2020-09-26 76 62 69.0 0.00 0.0 0
2020-09-27 83 61 72.0 0.00 0.0 0
2020-09-28 82 56 69.0 0.42 0.0 0
2020-09-29 70 49 59.5 0.00 0.0 0
2020-09-30 77 47 62.0 0.00 0.0 0
2020-10-01 76 51 63.5 0.00 0.0 0
2020-10-02 69 44 56.5 0.00 0.0 0
2020-10-03 71 40 55.5 0.00 0.0 0
2020-10-04 76 50 63.0 0.00 0.0 0
2020-10-05 76 48 62.0 0.00 0.0 0
2020-10-06 80 48 64.0 0.00 0.0 0
2020-10-07 82 52 67.0 0.00 0.0 0
2020-10-08 82 49 65.5 0.00 0.0 0
2020-10-09 73 63 68.0 0.47 0.0 0
2020-10-10 74 64 69.0 1.35 0.0 0
2020-10-11 75 68 71.5 0.23 0.0 0
2020-10-12 80 64 72.0 0.00 0.0 0
2020-10-13 76 52 64.0 0.00 0.0 0
2020-10-14 82 45 63.5 0.00 0.0 0
2020-10-15 80 54 67.0 0.00 0.0 0
2020-10-16 66 39 52.5 0.01 0.0 0
2020-10-17 68 37 52.5 0.00 0.0 0
2020-10-18 76 50 63.0 0.00 0.0 0
2020-10-19 80 56 68.0 0.00 0.0 0
2020-10-20 81 59 70.0 0.00 0.0 0
2020-10-21 81 58 69.5 0.00 0.0 0
2020-10-22 83 62 72.5 0.00 0.0 0
2020-10-23 83 63 73.0 0.03 0.0 0
2020-10-24 66 55 60.5 0.44 0.0 0
2020-10-25 69 55 62.0 0.00 0.0 0
2020-10-26 75 58 66.5 0.00 0.0 0
2020-10-27 75 58 66.5 T 0.0 0
2020-10-28 74 69 71.5 2.87 0.0 0
2020-10-29 72 48 60.0 0.58 0.0 0
2020-10-30 57 42 49.5 0.00 0.0 0
2020-10-31 68 40 54.0 0.00 0.0 0
2020-11-01 68 43 55.5 0.00 0.0 0
2020-11-02 57 33 45.0 0.00 0.0 0
2020-11-03 66 34 50.0 0.00 0.0 0
2020-11-04 71 39 55.0 0.00 0.0 0
2020-11-05 70 44 57.0 0.00 0.0 0
2020-11-06 76 46 61.0 0.00 0.0 0
2020-11-07 75 48 61.5 T 0.0 0
2020-11-08 79 59 69.0 0.00 0.0 0
2020-11-09 78 62 70.0 0.00 0.0 0
2020-11-10 74 65 69.5 T 0.0 0
2020-11-11 77 58 67.5 0.04 0.0 0
2020-11-12 68 44 56.0 0.00 0.0 0
2020-11-13 71 42 56.5 0.00 0.0 0
2020-11-14 73 41 57.0 0.00 0.0 0
2020-11-15 69 40 54.5 0.02 0.0 0
2020-11-16 63 32 47.5 0.00 0.0 0
2020-11-17 62 34 48.0 0.00 0.0 0
2020-11-18 64 31 47.5 0.00 0.0 0
2020-11-19 66 38 52.0 0.00 0.0 0
2020-11-20 72 40 56.0 0.00 0.0 0
2020-11-21 73 42 57.5 0.00 0.0 0
2020-11-22 69 46 57.5 0.02 0.0 0
2020-11-23 57 35 46.0 0.00 0.0 0
2020-11-24 65 32 48.5 0.00 0.0 0
2020-11-25 65 53 59.0 0.48 0.0 0
2020-11-26 62 40 51.0 0.00 0.0 0
2020-11-27 66 38 52.0 0.58 0.0 0
2020-11-28 57 41 49.0 T 0.0 0
2020-11-29 55 39 47.0 0.73 0.0 0
2020-11-30 44 30 37.0 0.08 T 0
2020-12-01 41 25 33.0 0.00 0.0 0
2020-12-02 52 20 36.0 0.00 0.0 0
2020-12-03 58 25 41.5 0.16 0.0 0
2020-12-04 48 35 41.5 0.82 0.0 0
2020-12-05 56 28 42.0 0.00 0.0 0
2020-12-06 59 30 44.5 T 0.0 0
2020-12-07 47 28 37.5 0.00 0.0 0
2020-12-08 49 25 37.0 0.00 0.0 0
2020-12-09 64 28 46.0 0.00 0.0 0
2020-12-10 71 35 53.0 0.00 0.0 0
2020-12-11 66 37 51.5 0.00 0.0 0
2020-12-12 63 46 54.5 0.30 0.0 0
2020-12-13 60 34 47.0 0.80 0.0 0
2020-12-14 44 35 39.5 0.81 0.0 0
2020-12-15 48 30 39.0 T 0.0 0
2020-12-16 50 35 42.5 0.26 0.0 0
2020-12-17 43 26 34.5 0.00 0.0 0
2020-12-18 50 23 36.5 0.00 0.0 0
2020-12-19 53 27 40.0 0.03 0.0 0
2020-12-20 51 40 45.5 0.16 0.0 0
2020-12-21 61 38 49.5 0.00 0.0 0
2020-12-22 60 31 45.5 0.00 0.0 0
2020-12-23 61 35 48.0 0.12 0.0 0
2020-12-24 52 28 40.0 1.13 T 0
2020-12-25 32 20 26.0 0.00 0.0 0
2020-12-26 50 18 34.0 0.00 0.0 0
2020-12-27 60 26 43.0 0.00 0.0 0
2020-12-28 57 37 47.0 0.00 0.0 0
2020-12-29 61 33 47.0 0.00 0.0 0
2020-12-30 69 41 55.0 0.00 0.0 0
2020-12-31 59 50 54.5 0.03 0.0 0
First of all, notice that some columns contain the value "T". To solve some of the questions, you'll have to replace those:
df = pd.read_csv(r"C:\users\....\DATA.csv", sep=";")
df.replace('T',0, inplace = True)
To get the datatypes:
df.info()
<class 'pandas.core.frame.DataFrame'>
RangeIndex: 366 entries, 0 to 365
Data columns (total 7 columns):
# Column Non-Null Count Dtype
--- ------ -------------- -----
0 Date 366 non-null object
1 MaxTemperature 366 non-null int64
2 MinTemperature 366 non-null int64
3 AvgTemperature 366 non-null float64
4 Precipitation 366 non-null object
5 Snowfall 366 non-null object
6 SnowDepth 366 non-null int64
dtypes: float64(1), int64(3), object(3)
memory usage: 20.1+ KB
To get all the information you ask, you need to transform object values to float. They are string because you hade "T" values instead of numeric:
df['Precipitation'] = df.Precipitation.astype(float)
df['Snowfall'] = df.Snowfall.astype(float)
df['SnowDepth'] = df.SnowDepth.astype(float)
Note now that
df.info()
<class 'pandas.core.frame.DataFrame'>
RangeIndex: 366 entries, 0 to 365
Data columns (total 7 columns):
# Column Non-Null Count Dtype
--- ------ -------------- -----
0 Date 366 non-null object
1 MaxTemperature 366 non-null int64
2 MinTemperature 366 non-null int64
3 AvgTemperature 366 non-null float64
4 Precipitation 366 non-null float64
5 Snowfall 366 non-null float64
6 SnowDepth 366 non-null float64
dtypes: float64(4), int64(2), object(1)
memory usage: 20.1+ KB
Now to answer all the questions:
df.describe()
returns:
MaxTemperature MinTemperature AvgTemperature Precipitation \
count 366.000000 366.000000 366.000000 366.000000
mean 73.021858 52.229508 62.625683 0.192678
std 14.496086 14.966696 14.317651 0.471406
min 28.000000 18.000000 25.000000 0.000000
25% 61.250000 40.000000 51.000000 0.000000
50% 74.000000 53.000000 63.250000 0.000000
75% 86.000000 67.000000 75.500000 0.140000
max 98.000000 75.000000 86.000000 3.420000
Snowfall SnowDepth
count 366.0 366.0
mean 0.0 0.0
std 0.0 0.0
min 0.0 0.0
25% 0.0 0.0
50% 0.0 0.0
75% 0.0 0.0
max 0.0 0.0
you have the max, min, .... for all variables.
As for the plot
lines = df.plot.line()
I have a .dat file which I tried to do analysis upon. This is the code
catalog=ascii.read("table6.dat",Reader=ascii.NoHeader,guess=False,fast_reader=False,delimiter='\s')
The problem is that there are missing values(empty) within the file which does not allow me to do analysis on the data.
output:
astropy.io.ascii.core.InconsistentTableError: Number of header columns (23) inconsistent with data columns (24) at data line 3
changing the delimiter from '\s' to '\n' gives me this
col1
-------------------------------------------------------------------------------------------------------------------------------------
1 33 Psc 28 00 05 20.1 -05 42 27 93.73 -65.93 111 -6.6 -13 89 (44) -3 45 -101 -16.7 37.4 24.6
2 ADS 48A 38 00 05 41.2 45 48 35 114.64 -16.32 11 -9.0 886 -207 (737) -4 10 -3 -33.6 -31.1 -15.4
3 5 Cet 352 00 08 12.0 -02 26 52 98.32 -63.23 140 -0.4 6 -4 (77) -9 62 -125 -2.1 -4.1 -1.4
4 BD Cet 1833 00 22 46.7 -09 13 49 100.84 -70.86 71 -4.8 3 -51 (409) -4 23 -67 8.1 -15.9 -0.9
5 13 Cet A 3196 00 35 14.8 -03 35 34 112.87 -66.15 21 10.6 410 -21 (409) -3 8 -19 -36.0 -19.3 -12.7
6 FF And 00 42 47.3 35 32 50 120.95 -27.29 24 -0.5 250 90 (380) -11 18 -11 -26.3 -11.6 8.6
7 zeta And 4502 00 47 20.3 24 16 02 121.73 -38.60 31 -23.7 -100 -83 (737) -13 21 -19 26.5 -14.0 5.2
8 CF Tuc 5303 00 52 58.3 -74 39 07 302.81 -42.48 54 0.5 19 28 (409) 22 -33 -36 -6.6 1.0 -5.5
9 BD+25 161 6286 01 04 07.1 26 35 13 126.44 -36.20 55 -20.0 -12 -18 (737) -26 36 -32 13.7 -13.5 7.7
10 AY Cet 7672 01 16 36.2 -02 30 01 137.72 -64.65 67 -30.1 -108 -59 (409) -21 19 -60 46.6 -2.7 15.6
...
196 IM Peg 216489 22 53 02.3 16 50 28 86.36 -37.48 50 -12.8 -19 -24 (737) 3 40 -30 6.3 -11.9 6.0
197 AZ Psc 217188 22 58 52.7 00 18 58 73.71 -51.46 260 -20.5 39 16 (409) 45 156 -203 -54.2 -12.3 5.5
198 TZ PsA 217344 23 00 27.7 -33 44 34 10.64 -65.25 46 36.9 -44 -132 (409) 19 4 -42 32.1 -21.4 -28.2
199 KU Peg 218153 23 05 29.3 26 00 33 95.03 -31.05 950 -80.4 51 -9 (737) -71 811 -490 -171.4 -159.1 -78.5
200 KZ And 218738 23 09 57.4 47 57 30 105.90 -11.53 23 -6.9 157 -5 (737) -6 22 -5 -12.7 -12.2 -5.5
201 RT And 23 11 10.0 53 01 33 108.06 -6.92 95 20.0 -12 -18 (737) -29 90 -11 1.5 20.8 -7.9
202 SZ Psc 219113 23 13 23.8 02 40 32 80.66 -51.96 125 12.0 12 29 (737) 13 76 -98 -13.5 17.2 -3.5
203 EZ Peg 23 16 53.4 25 43 09 97.58 -32.45 83 -27.2 -70 13 (409) -9 69 -45 24.8 -10.9 28.1
204 lambda And 222107 23 37 33.9 46 27 29 109.90 -14.53 23 6.8 162 -421 (737) -8 21 -6 -1.8 -6.7 -49.2
205 KT Peg 222317 23 39 31.0 28 14 47 104.22 -32.00 25 -3.1 299 226 (737) -5 21 -13 -41.9 -6.0 13.8
206 II Peg 224085 23 55 04.0 28 38 01 108.22 -32.62 29 -18.1 574 27 (737) -8 24 -16 -66.5 -48.1 -3.8
but the header cannot be separately allocated to the columns.
there is a missing value in rows 6, 201, 203 in the third column(shown values).
the problem could be solved if false values could be given to these missing empty fields.
I can't find any documentation relating to this...
The problem is that there is fundamentally no way for the table parser to unambiguously know where the column boundaries are for your data file. Your table data are in fixed-width format, meaning that each column lives within certain character bounds in each line. You need to specify those bounds in some way.
This is documented here with examples:
https://docs.astropy.org/en/latest/io/ascii/fixed_width_gallery.html#fixed-width-gallery
If you can modify the file, the easiest way is to add a header line which tells the parser what the column boundaries are. For example:
Col1 Col2 Col3 Col4
---- --------- ---- ----
1.2 "hello" 1 a
2.4 's worlds 2 2
If you cannot modify the file itself, then you can explicitly specify the column starts and stops, as shown in the second example in this section: https://docs.astropy.org/en/latest/io/ascii/fixed_width_gallery.html#fixedwidthnoheader
I wish to plot a XRD pattern using Gnuplot. The data file is given below
# User :
# Journal :
# Sample Details :
# Col 1: 2theta (deg.), Col 2: Intensity (a.u.)
20 88
20.05 92
20.1 96
20.15 88
20.2 84
20.25 100
20.3 94
20.35 84
20.4 78
20.45 81
20.5 86
20.55 92
20.6 85
20.65 74
20.7 83
20.75 74
20.8 87
20.85 67
20.9 85
20.95 83
21 90
21.05 81
21.1 87
21.15 84
21.2 83
21.25 84
21.3 86
21.35 92
21.4 92
21.45 73
21.5 97
21.55 96
21.6 88
21.65 95
21.7 93
21.75 83
21.8 91
21.85 91
21.9 76
21.95 85
22 89
22.05 87
22.1 72
22.15 85
22.2 71
22.25 68
22.3 75
22.35 63
22.4 64
22.45 76
22.5 72
22.55 78
22.6 62
22.65 80
22.7 80
22.75 78
22.8 85
22.85 62
22.9 74
22.95 84
23 73
23.05 76
23.1 83
23.15 48
23.2 74
23.25 79
23.3 75
23.35 70
23.4 94
23.45 80
23.5 79
23.55 69
23.6 73
23.65 55
23.7 72
23.75 59
23.8 87
23.85 76
23.9 70
23.95 76
24 74
24.05 76
24.1 89
24.15 79
24.2 84
24.25 72
24.3 69
24.35 74
24.4 72
24.45 85
24.5 65
24.55 85
24.6 68
24.65 71
24.7 70
24.75 70
24.8 75
24.85 73
24.9 79
24.95 76
25 78
25.05 68
25.1 67
25.15 62
25.2 72
25.25 65
25.3 78
25.35 74
25.4 67
25.45 77
25.5 70
25.55 82
25.6 80
25.65 64
25.7 71
25.75 67
25.8 70
25.85 73
25.9 80
25.95 69
26 61
26.05 82
26.1 86
26.15 83
26.2 88
26.25 68
26.3 78
26.35 66
26.4 71
26.45 69
26.5 61
26.55 73
26.6 74
26.65 83
26.7 72
26.75 82
26.8 84
26.85 72
26.9 68
26.95 72
27 63
27.05 66
27.1 68
27.15 65
27.2 75
27.25 72
27.3 66
27.35 58
27.4 67
27.45 73
27.5 74
27.55 84
27.6 80
27.65 82
27.7 70
27.75 71
27.8 70
27.85 76
27.9 73
27.95 85
28 82
28.05 75
28.1 70
28.15 85
28.2 80
28.25 96
28.3 126
28.35 173
28.4 219
28.45 270
28.5 214
28.55 158
28.6 105
28.65 78
28.7 75
28.75 82
28.8 83
28.85 74
28.9 79
28.95 77
29 61
29.05 75
29.1 75
29.15 65
29.2 69
29.25 79
29.3 68
29.35 78
29.4 74
29.45 57
29.5 75
29.55 65
29.6 69
29.65 83
29.7 72
29.75 69
29.8 65
29.85 68
29.9 89
29.95 79
30 84
30.05 110
30.1 129
30.15 146
30.2 150
30.25 136
30.3 117
30.35 81
30.4 72
30.45 85
30.5 75
30.55 71
30.6 70
30.65 72
30.7 87
30.75 67
30.8 71
30.85 75
30.9 80
30.95 76
31 78
31.05 72
31.1 66
31.15 85
31.2 61
31.25 62
31.3 69
31.35 75
31.4 51
31.45 48
31.5 55
31.55 77
31.6 66
31.65 84
31.7 64
31.75 69
31.8 74
31.85 53
31.9 77
31.95 68
32 74
32.05 53
32.1 67
32.15 61
32.2 68
32.25 77
32.3 62
32.35 57
32.4 62
32.45 62
32.5 62
32.55 66
32.6 56
32.65 55
32.7 62
32.75 61
32.8 67
32.85 74
32.9 49
32.95 66
33 82
33.05 57
33.1 59
33.15 61
33.2 62
33.25 74
33.3 60
33.35 72
33.4 66
33.45 71
33.5 58
33.55 66
33.6 59
33.65 66
33.7 53
33.75 70
33.8 52
33.85 66
33.9 58
33.95 65
34 47
34.05 51
34.1 56
34.15 55
34.2 77
34.25 70
34.3 64
34.35 59
34.4 62
34.45 51
34.5 62
34.55 48
34.6 45
34.65 59
34.7 65
34.75 64
34.8 83
34.85 75
34.9 125
34.95 149
35 152
35.05 120
35.1 84
35.15 76
35.2 70
35.25 63
35.3 68
35.35 51
35.4 64
35.45 62
35.5 58
35.55 63
35.6 67
35.65 68
35.7 62
35.75 58
35.8 59
35.85 48
35.9 53
35.95 55
36 54
36.05 56
36.1 49
36.15 53
36.2 66
36.25 60
36.3 63
36.35 61
36.4 48
36.45 67
36.5 61
36.55 50
36.6 48
36.65 46
36.7 70
36.75 54
36.8 62
36.85 62
36.9 45
36.95 56
37 44
37.05 59
37.1 58
37.15 53
37.2 49
37.25 49
37.3 54
37.35 51
37.4 48
37.45 49
37.5 56
37.55 47
37.6 53
37.65 50
37.7 47
37.75 48
37.8 64
37.85 61
37.9 56
37.95 44
38 44
38.05 43
38.1 45
38.15 51
38.2 61
38.25 48
38.3 39
38.35 58
38.4 50
38.45 56
38.5 49
38.55 54
38.6 47
38.65 47
38.7 46
38.75 49
38.8 43
38.85 50
38.9 51
38.95 60
39 69
39.05 46
39.1 68
39.15 44
39.2 42
39.25 46
39.3 52
39.35 43
39.4 46
39.45 52
39.5 57
39.55 46
39.6 48
39.65 47
39.7 51
39.75 61
39.8 48
39.85 53
39.9 59
39.95 46
40 53
40.05 51
40.1 49
40.15 56
40.2 49
40.25 50
40.3 52
40.35 58
40.4 62
40.45 99
40.5 119
40.55 161
40.6 135
40.65 163
40.7 130
40.75 105
40.8 80
40.85 68
40.9 53
40.95 55
41 53
41.05 54
41.1 59
41.15 56
41.2 53
41.25 52
41.3 46
41.35 47
41.4 44
41.45 57
41.5 49
41.55 48
41.6 42
41.65 45
41.7 46
41.75 48
41.8 44
41.85 51
41.9 45
41.95 54
42 44
42.05 46
42.1 43
42.15 53
42.2 50
42.25 38
42.3 42
42.35 51
42.4 51
42.45 42
42.5 36
42.55 36
42.6 53
42.65 44
42.7 38
42.75 45
42.8 55
42.85 33
42.9 50
42.95 58
43 48
43.05 46
43.1 51
43.15 44
43.2 58
43.25 47
43.3 47
43.35 59
43.4 42
43.45 50
43.5 50
43.55 45
43.6 48
43.65 51
43.7 38
43.75 51
43.8 57
43.85 49
43.9 59
43.95 40
44 41
44.05 39
44.1 37
44.15 43
44.2 43
44.25 52
44.3 50
44.35 46
44.4 41
44.45 48
44.5 44
44.55 40
44.6 47
44.65 39
44.7 49
44.75 49
44.8 44
44.85 38
44.9 44
44.95 53
45 46
45.05 51
45.1 31
45.15 38
45.2 51
45.25 42
45.3 47
45.35 46
45.4 37
45.45 66
45.5 53
45.55 40
45.6 45
45.65 39
45.7 47
45.75 39
45.8 45
45.85 38
45.9 48
45.95 42
46 35
46.05 46
46.1 45
46.15 34
46.2 55
46.25 39
46.3 35
46.35 50
46.4 32
46.45 49
46.5 50
46.55 36
46.6 46
46.65 51
46.7 41
46.75 41
46.8 53
46.85 54
46.9 50
46.95 43
47 44
47.05 61
47.1 36
47.15 43
47.2 48
47.25 38
47.3 46
47.35 48
47.4 51
47.45 42
47.5 51
47.55 37
47.6 40
47.65 49
47.7 33
47.75 36
47.8 41
47.85 49
47.9 39
47.95 42
48 58
48.05 51
48.1 43
48.15 48
48.2 46
48.25 34
48.3 44
48.35 39
48.4 44
48.45 46
48.5 35
48.55 35
48.6 51
48.65 43
48.7 45
48.75 54
48.8 48
48.85 41
48.9 49
48.95 52
49 36
49.05 42
49.1 38
49.15 44
49.2 44
49.25 38
49.3 49
49.35 54
49.4 52
49.45 39
49.5 41
49.55 66
49.6 51
49.65 38
49.7 34
49.75 52
49.8 46
49.85 60
49.9 47
49.95 45
50 68
50.05 66
50.1 68
50.15 89
50.2 133
50.25 137
50.3 125
50.35 124
50.4 103
50.45 88
50.5 72
50.55 59
50.6 56
50.65 46
50.7 39
50.75 51
50.8 27
50.85 45
50.9 41
50.95 43
51 51
51.05 49
51.1 45
51.15 38
51.2 48
51.25 43
51.3 42
51.35 44
51.4 45
51.45 49
51.5 40
51.55 43
51.6 37
51.65 50
51.7 47
51.75 37
51.8 39
51.85 43
51.9 42
51.95 40
52 45
52.05 34
52.1 32
52.15 43
52.2 37
52.25 47
52.3 62
52.35 36
52.4 45
52.45 36
52.5 37
52.55 38
52.6 37
52.65 35
52.7 38
52.75 47
52.8 40
52.85 50
52.9 50
52.95 44
53 44
53.05 35
53.1 46
53.15 43
53.2 40
53.25 57
53.3 29
53.35 39
53.4 39
53.45 43
53.5 51
53.55 44
53.6 53
53.65 40
53.7 41
53.75 59
53.8 46
53.85 46
53.9 57
53.95 52
54 48
54.05 50
54.1 40
54.15 42
54.2 46
54.25 48
54.3 47
54.35 42
54.4 49
54.45 43
54.5 43
54.55 54
54.6 44
54.65 40
54.7 45
54.75 34
54.8 42
54.85 40
54.9 34
54.95 43
55 51
55.05 56
55.1 42
55.15 37
55.2 41
55.25 49
55.3 53
55.35 46
55.4 47
55.45 39
55.5 43
55.55 43
55.6 41
55.65 38
55.7 36
55.75 55
55.8 45
55.85 37
55.9 47
55.95 50
56 46
56.05 51
56.1 51
56.15 56
56.2 31
56.25 44
56.3 41
56.35 45
56.4 45
56.45 49
56.5 45
56.55 60
56.6 30
56.65 38
56.7 51
56.75 54
56.8 45
56.85 38
56.9 40
56.95 41
57 36
57.05 35
57.1 45
57.15 41
57.2 49
57.25 36
57.3 38
57.35 43
57.4 43
57.45 41
57.5 42
57.55 42
57.6 41
57.65 39
57.7 37
57.75 48
57.8 42
57.85 56
57.9 45
57.95 39
58 51
58.05 40
58.1 47
58.15 39
58.2 46
58.25 37
58.3 41
58.35 36
58.4 50
58.45 42
58.5 58
58.55 36
58.6 59
58.65 57
58.7 57
58.75 68
58.8 61
58.85 68
58.9 58
58.95 54
59 53
59.05 59
59.1 48
59.15 49
59.2 42
59.25 49
59.3 45
59.35 38
59.4 44
59.45 54
59.5 37
59.55 52
59.6 62
59.65 70
59.7 73
59.75 88
59.8 69
59.85 62
59.9 60
59.95 51
60 59
60.05 51
60.1 45
60.15 45
60.2 39
60.25 55
60.3 48
60.35 45
60.4 34
60.45 47
60.5 32
60.55 40
60.6 40
60.65 54
60.7 35
60.75 50
60.8 40
60.85 34
60.9 39
60.95 31
61 27
61.05 45
61.1 47
61.15 41
61.2 34
61.25 46
61.3 42
61.35 33
61.4 45
61.45 41
61.5 31
61.55 42
61.6 40
61.65 32
61.7 35
61.75 33
61.8 45
61.85 48
61.9 50
61.95 44
62 36
62.05 34
62.1 44
62.15 47
62.2 40
62.25 42
62.3 50
62.35 51
62.4 43
62.45 46
62.5 59
62.55 50
62.6 56
62.65 63
62.7 67
62.75 54
62.8 61
62.85 54
62.9 43
62.95 44
63 36
63.05 49
63.1 41
63.15 46
63.2 44
63.25 36
63.3 34
63.35 36
63.4 58
63.45 42
63.5 40
63.55 48
63.6 43
63.65 35
63.7 36
63.75 42
63.8 41
63.85 40
63.9 39
63.95 40
64 32
64.05 46
64.1 44
64.15 41
64.2 44
64.25 35
64.3 45
64.35 46
64.4 37
64.45 43
64.5 36
64.55 40
64.6 36
64.65 45
64.7 38
64.75 42
64.8 37
64.85 39
64.9 50
64.95 40
65 28
65.05 34
65.1 41
65.15 42
65.2 40
65.25 45
65.3 34
65.35 44
65.4 49
65.45 49
65.5 46
65.55 36
65.6 40
65.65 51
65.7 30
65.75 48
65.8 34
65.85 52
65.9 32
65.95 43
66 41
66.05 42
66.1 61
66.15 57
66.2 55
66.25 44
66.3 63
66.35 78
66.4 80
66.45 77
66.5 98
66.55 86
66.6 81
66.65 61
66.7 62
66.75 59
66.8 54
66.85 50
66.9 52
66.95 32
67 35
67.05 39
67.1 47
67.15 39
67.2 51
67.25 53
67.3 35
67.35 41
67.4 38
67.45 25
67.5 48
67.55 41
67.6 37
67.65 45
67.7 37
67.75 29
67.8 32
67.85 28
67.9 31
67.95 41
68 33
68.05 44
68.1 48
68.15 39
68.2 46
68.25 49
68.3 39
68.35 40
68.4 50
68.45 40
68.5 54
68.55 44
68.6 35
68.65 31
68.7 46
68.75 28
68.8 38
68.85 29
68.9 34
68.95 43
69 49
69.05 37
69.1 43
69.15 44
69.2 31
69.25 33
69.3 43
69.35 47
69.4 42
69.45 39
69.5 37
69.55 35
69.6 42
69.65 44
69.7 37
69.75 53
69.8 24
69.85 35
69.9 41
69.95 34
70 42
70.05 37
70.1 22
70.15 47
70.2 35
70.25 31
70.3 52
70.35 37
70.4 41
70.45 40
70.5 47
70.55 44
70.6 39
70.65 47
70.7 30
70.75 39
70.8 41
70.85 36
70.9 25
70.95 41
71 33
71.05 35
71.1 32
71.15 35
71.2 38
71.25 45
71.3 45
71.35 57
71.4 41
71.45 30
71.5 28
71.55 34
71.6 42
71.65 41
71.7 32
71.75 25
71.8 43
71.85 45
71.9 33
71.95 34
72 44
72.05 43
72.1 45
72.15 42
72.2 42
72.25 30
72.3 44
72.35 47
72.4 36
72.45 45
72.5 40
72.55 45
72.6 33
72.65 39
72.7 47
72.75 39
72.8 40
72.85 34
72.9 39
72.95 30
73 31
73.05 37
73.1 35
73.15 39
73.2 37
73.25 34
73.3 38
73.35 41
73.4 34
73.45 50
73.5 46
73.55 44
73.6 54
73.65 57
73.7 81
73.75 71
73.8 83
73.85 80
73.9 70
73.95 50
74 61
74.05 39
74.1 58
74.15 46
74.2 33
74.25 40
74.3 41
74.35 38
74.4 48
74.45 49
74.5 46
74.55 39
74.6 46
74.65 43
74.7 31
74.75 37
74.8 32
74.85 32
74.9 44
74.95 34
75 29
75.05 31
75.1 33
75.15 52
75.2 32
75.25 29
75.3 29
75.35 36
75.4 28
75.45 28
75.5 45
75.55 25
75.6 30
75.65 26
75.7 32
75.75 32
75.8 44
75.85 40
75.9 30
75.95 34
76 44
76.05 41
76.1 46
76.15 30
76.2 39
76.25 38
76.3 43
76.35 30
76.4 47
76.45 31
76.5 34
76.55 36
76.6 45
76.65 36
76.7 32
76.75 30
76.8 34
76.85 37
76.9 37
76.95 41
77 37
77.05 30
77.1 40
77.15 47
77.2 34
77.25 44
77.3 35
77.35 41
77.4 33
77.45 36
77.5 29
77.55 38
77.6 32
77.65 45
77.7 34
77.75 29
77.8 36
77.85 33
77.9 35
77.95 34
78 40
78.05 43
78.1 33
78.15 35
78.2 40
78.25 43
78.3 38
78.35 38
78.4 43
78.45 40
78.5 42
78.55 38
78.6 34
78.65 34
78.7 40
78.75 37
78.8 37
78.85 39
78.9 47
78.95 40
79 35
79.05 34
79.1 40
79.15 39
79.2 33
79.25 38
79.3 32
79.35 48
79.4 39
79.45 35
79.5 37
79.55 32
79.6 40
79.65 36
79.7 40
79.75 40
79.8 26
79.85 39
79.9 49
79.95 36
80 43
My script is provided below
set terminal postscript eps enhanced colour font 'Times-Roman,12' size 4in,3in
set output "XRD_E1.eps"
set style line 1 lt 1 lw 1 lc rgb "black"
set xtics out scale 1.5
set ytics out scale 1.5
set yrange [0:350]
set format y ''
set tics font ",16"
set xlabel "2{/Symbol \161} (deg.)" font ",16"
set ylabel "Intensity (a.u.)" font ",16"
set key inside right top
set key title "As prepared LiCl-KCl \n " font ",14"
##
set label 1 '(200)' font ",12" at 28.45, 280 point pt 7 ps 1.75 lt rgb "red" offset -0.50, 0.50 rotate by 90
set label 2 '(111)' font ",12" at 30.20, 160 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
set label 3 '(200)' font ",12" at 35.00, 160 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
set label 4 '(220)' font ",12" at 40.65, 173 point pt 7 ps 1.75 lt rgb "red" offset -0.50,0.50 rotate by 90
set label 5 '(220)' font ",12" at 50.25, 147 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
set label 6 '(400)' font ",12" at 58.85, 78 point pt 7 ps 1.75 lt rgb "red" offset -1.00,0.50 rotate by 90
set label 7 '(311)' font ",12" at 59.75, 98 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
set label 8 '(222)' font ",12" at 62.70, 77 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
set label 9 '(420)' font ",12" at 66.50, 108 point pt 7 ps 1.75 lt rgb "red" offset -0.50,0.50 rotate by 90
set label 10 '(222)' font ",12" at 73.80, 93 point pt 7 ps 1.75 lt rgb "blue" offset -0.50,0.50 rotate by 90
##
plot [10:90] 'XRD_E1.dat' u 1:2 w l ls 1 notitle
The script works fine. I only need to include the point types used in the plot in the key title with a proper spacing.
Secondly, is there a better way to plot and label than what is provided in the script?
Thank you
#Suddhasattwa Ghosh, in case this is still of interest, you can simply plot your marks with labels point (check help labels). Put your peak data into a datablock or in separate files.
Script:
### print with labels and points
reset session
FILE = 'XRD_E1.dat'
set tics font ",16"
set xlabel "2{/Symbol \161} (deg.)" font ",16"
set xtics out scale 1.5
set ylabel "Intensity (a.u.)" font ",16"
set yrange [0:350]
set format y ''
set ytics out scale 1.5
set key inside right top noautotitle font ",12" title "As prepared LiCl-KCl \n " font ",14"
$LiCl <<EOD
(200) 28.45 280
(220) 40.65 173
(400) 58.85 78
(420) 66.50 108
EOD
$KCl <<EOD
(111) 30.20 160
(200) 35.00 160
(220) 50.25 147
(311) 59.75 98
(222) 62.70 77
(222) 73.80 93
EOD
plot FILE u 1:2 w l lc "black", \
$LiCl u 2:3:1 w labels point pt 7 lc "red" offset -0.5,0.5 left rotate by 90 font ",12" ti "LiCl", \
$KCl u 2:3:1 w labels point pt 7 lc "blue" offset -0.5,0.5 left rotate by 90 font ",12" ti "KCl"
### end of script
Result:
If I understand well, you want something like this:
To achieve this, extend your code with:
set key horizontal
plot [10:90] 'XRD_E1.dat' u 1:2 w l ls 1 notitle, 1/0 w p pt 7 ps 1.75 lc rgb "red" t 'LiCl', 1/0 w p pt 7 ps 1.75 lc rgb "blue" t 'KCl'
I have an image which is displayed in path attribute in svg with viewbox ( in the code below )
<svg class="map" height="50000" width="50000">
<svg class="may" height="300" width="300" preserveAspectRatio="none" viewBox="0 0 17275 8599">
<g>
<path d="M12620 8613 c-583 -56 -1102 -244 -1506 -543 -116 -86 -297 -260 -388 -373 l-68 -85 -171 83 c-358 173 -657 271 -1097 359 -492 99 -847 129 -1515 129 -435 0 -568 -7 -875 -44 -810 -97 -1468 -299 -1885 -578 -66 -44 -149 -104 -184 -134 l-65 -53 -135 44 c-562 181 -1401 248 -2112 166 -610 -69 -1147 -238 -1482 -466 -51 -34 -133 -103 -183 -153 -135 -135 -193 -242 -214 -397 -29 -207 75 -411 304 -597 124 -100 246 -168 505 -280 96 -42 176 -81 178 -86 2 -6 -24 -16 -56 -23 -139 -29 -508 -167 -726 -271 -241 -116 -390 -215 -526 -350 -135 -135 -201 -254 -218 -391 -16 -126 -13 -178 14 -254 66 -189 215 -359 452 -515 l101 -68 -160 -159 c-297 -296 -450 -537 -527 -831 -117 -447 -26 -873 269 -1268 257 -344 655 -633 1155 -838 766 -314 1794 -380 2662 -172 293 71 538 161 821 305 295 149 434 251 688 504 88 89 183 193 210 232 l50 72 12 -42 c52 -194 136 -337 296 -504 242 -251 557 -450 976 -615 397 -157 876 -275 1429 -352 297 -41 898 -55 1493 -34 242 8 343 16 499 39 568 84 1001 193 1414 357 511 202 820 418 1082 753 88 113 160 279 183 425 7 42 8 108 4 168 l-7 97 162 0 c326 0 727 29 975 72 153 26 436 97 596 149 426 141 737 342 897 582 68 102 86 168 86 312 0 106 -3 128 -26 188 -35 89 -62 127 -201 280 -64 71 -116 132 -116 135 0 4 87 36 193 71 804 266 1258 636 1383 1130 48 186 22 354 -86 571 -110 220 -274 387 -549 559 -295 184 -610 313 -1027 421 -205 53 -239 64 -248 79 -3 5 8 63 26 128 30 112 32 127 32 303 1 272 -27 390 -145 620 -242 471 -766 845 -1447 1035 -286 79 -499 107 -862 110 -162 1 -315 1 -340 -2z m565 -208 c50 -8 138 -19 196 -25 59 -6 149 -21 200 -35 52 -14 144 -39 204 -55 181 -48 301 -93 369 -139 22 -15 108 -56 191 -90 129 -54 161 -72 240 -135 49 -41 103 -86 118 -100 15 -14 32 -26 37 -26 20 0 213 -206 237 -255 9 -16 37 -57 62 -90 26 -33 59 -80 73 -105 30 -51 91 -207 103 -260 4 -19 18 -69 31 -110 17 -54 24 -98 24 -158 0 -101 -16 -218 -36 -254 -8 -14 -12 -33 -9 -40 6 -15 -15 -127 -30 -160 -5 -14 -2 -18 15 -18 12 0 54 -11 93 -25 78 -27 201 -56 257 -61 89 -8 353 -99 462 -159 14 -8 32 -15 38 -15 7 0 59 -22 116 -50 57 -27 112 -50 122 -50 25 0 286 -171 383 -252 26 -21 52 -38 58 -38 6 0 11 -4 11 -8 0 -5 12 -21 28 -38 15 -16 34 -42 42 -57 8 -16 27 -35 42 -43 30 -15 95 -97 123 -154 9 -19 28 -46 41 -60 12 -14 30 -42 38 -62 20 -48 33 -178 18 -178 -8 0 -10 -41 -5 -142 6 -141 5 -144 -21 -195 -14 -29 -26 -59 -26 -67 0 -9 -9 -32 -21 -53 -69 -126 -106 -174 -226 -298 -73 -74 -133 -139 -133 -144 0 -8 -44 -32 -98 -52 -19 -7 -38 -22 -43 -36 -5 -13 -17 -23 -28 -23 -11 0 -25 -9 -31 -20 -6 -11 -19 -20 -29 -20 -10 0 -24 -7 -31 -15 -13 -16 -148 -89 -220 -119 -25 -11 -67 -34 -95 -52 -30 -20 -82 -42 -130 -53 -112 -28 -175 -51 -286 -105 -53 -25 -105 -46 -115 -46 -10 0 -25 -4 -32 -9 -17 -10 92 -95 198 -155 9 -5 31 -35 48 -68 18 -32 48 -73 66 -91 32 -33 33 -35 38 -142 8 -145 -3 -179 -126 -394 -23 -40 -38 -54 -72 -67 -24 -9 -51 -27 -59 -41 -9 -13 -42 -41 -73 -61 -31 -20 -73 -49 -92 -64 -36 -27 -224 -118 -245 -118 -4 0 -48 -17 -98 -39 -127 -53 -358 -127 -441 -141 -38 -6 -84 -17 -102 -25 -18 -7 -90 -21 -161 -30 -70 -9 -182 -26 -248 -37 -222 -37 -369 -49 -656 -55 l-286 -5 -1 -41 c0 -107 -21 -270 -47 -357 -24 -83 -33 -102 -75 -145 -26 -27 -60 -76 -76 -108 -15 -32 -43 -72 -61 -90 -19 -18 -57 -55 -86 -82 -56 -54 -202 -160 -241 -175 -13 -4 -46 -29 -73 -54 -51 -47 -303 -180 -443 -234 -254 -97 -467 -169 -650 -218 -74 -20 -157 -43 -185 -51 -27 -7 -96 -18 -153 -23 -56 -5 -106 -11 -110 -14 -5 -3 -91 -19 -192 -35 -102 -17 -207 -38 -234 -46 -65 -20 -385 -34 -936 -41 -346 -4 -454 -3 -579 10 -85 9 -189 16 -231 16 -43 0 -136 9 -206 19 -71 10 -160 22 -199 26 -38 4 -106 15 -150 25 -44 10 -123 24 -175 30 -52 6 -156 27 -230 46 -74 19 -187 43 -252 53 -110 18 -169 38 -183 61 -3 5 -22 10 -42 10 -43 0 -105 20 -116 37 -4 6 -44 23 -89 38 -45 15 -109 41 -142 59 -34 17 -95 45 -136 61 -90 35 -203 97 -246 135 -18 15 -47 30 -66 34 -18 3 -48 20 -66 36 -18 17 -40 30 -47 30 -8 0 -29 15 -47 33 -18 17 -51 45 -73 60 -22 15 -62 53 -90 83 -27 31 -75 80 -107 110 -41 41 -62 71 -79 116 -16 43 -31 66 -51 77 -16 10 -30 28 -34 46 -8 36 -65 155 -75 155 -4 0 -12 -13 -18 -28 -7 -15 -34 -46 -62 -68 -27 -21 -58 -54 -69 -71 -11 -18 -41 -48 -67 -65 -26 -18 -73 -58 -103 -89 -30 -30 -76 -70 -102 -87 -25 -17 -48 -35 -50 -40 -1 -4 -24 -21 -49 -37 -25 -17 -78 -51 -117 -77 -73 -49 -208 -118 -229 -118 -7 0 -16 -6 -20 -14 -12 -21 -185 -100 -293 -135 -52 -16 -171 -55 -265 -85 -167 -54 -436 -115 -625 -142 -52 -8 -141 -21 -197 -29 -67 -11 -215 -18 -442 -22 -300 -5 -345 -4 -383 10 -33 13 -74 16 -173 15 -96 -1 -143 3 -180 15 -27 8 -70 18 -95 22 -55 8 -271 58 -360 85 -36 10 -94 24 -130 30 -36 7 -77 18 -93 26 -15 8 -52 19 -82 25 -30 5 -101 32 -158 58 -56 26 -136 60 -177 76 -41 15 -80 32 -86 37 -6 4 -49 27 -95 50 -46 23 -102 57 -124 75 -63 53 -68 57 -96 73 -184 103 -210 122 -303 210 -150 142 -186 181 -186 201 0 11 -4 19 -8 19 -5 0 -14 10 -19 23 -6 13 -38 57 -71 98 -83 103 -212 367 -212 436 -1 26 -6 68 -11 93 -6 25 -14 115 -19 200 -8 144 -7 161 15 250 28 112 36 132 131 300 17 30 34 67 37 82 4 15 15 29 25 32 9 3 37 31 62 61 25 30 48 55 53 55 4 0 7 8 7 18 0 9 16 28 35 41 19 13 35 30 35 37 0 8 17 26 39 42 37 27 57 45 178 163 32 30 77 68 101 84 23 15 42 29 42 30 0 2 -29 17 -65 34 -60 28 -129 87 -272 234 -16 16 -61 61 -100 101 -40 40 -73 77 -73 82 0 5 -15 33 -34 64 -19 30 -39 75 -46 100 -6 25 -18 64 -26 88 -28 84 -6 228 45 300 11 16 29 49 40 73 12 27 42 63 77 94 32 28 83 75 114 105 30 30 69 61 85 69 45 20 63 30 147 82 86 53 243 130 271 132 9 1 17 5 17 10 0 4 4 6 9 3 5 -4 11 -2 13 3 6 18 347 145 501 186 49 13 96 30 106 39 10 9 28 16 40 16 12 0 31 5 42 10 30 17 4 36 -81 59 -40 11 -77 25 -84 30 -6 5 -28 12 -48 16 -21 4 -38 11 -38 16 0 5 -11 9 -25 9 -14 0 -25 5 -25 10 0 6 -7 10 -15 10 -8 0 -15 4 -15 8 0 4 -20 14 -45 21 -24 7 -50 20 -57 29 -7 8 -32 24 -55 34 -24 10 -55 30 -70 44 -14 13 -37 27 -50 30 -13 4 -23 10 -23 15 0 5 -13 15 -29 23 -31 16 -72 49 -102 81 -108 114 -143 168 -180 277 -29 86 -26 216 6 295 29 71 59 126 94 169 14 18 33 41 41 52 8 10 47 43 85 73 39 29 72 56 75 59 3 4 51 35 107 69 188 115 475 231 732 295 266 67 653 122 934 133 81 3 147 9 147 12 0 11 565 5 750 -7 91 -6 192 -18 225 -27 33 -9 61 -12 63 -7 4 13 101 2 134 -14 15 -8 49 -14 76 -14 30 0 97 -16 173 -40 74 -25 166 -46 229 -54 58 -8 124 -21 147 -29 41 -15 41 -15 47 9 5 17 22 32 59 48 28 14 65 38 81 55 16 16 41 33 55 36 15 3 33 15 41 25 8 11 20 20 26 20 6 0 17 7 25 16 7 8 36 27 63 41 28 14 58 31 66 38 8 6 58 29 110 50 52 21 106 45 119 54 73 48 574 205 754 236 48 8 111 24 140 35 62 24 201 50 267 50 25 0 66 6 91 14 149 46 367 59 1034 61 302 1 442 -2 500 -11 44 -7 145 -18 225 -24 80 -5 215 -17 300 -26 85 -8 205 -19 265 -23 61 -5 117 -11 125 -15 8 -3 49 -12 90 -20 41 -7 125 -26 185 -40 61 -15 139 -31 175 -36 80 -11 190 -42 250 -69 25 -11 53 -21 62 -21 9 0 38 -11 65 -24 26 -13 80 -31 118 -41 68 -16 134 -41 243 -91 29 -13 59 -24 67 -24 7 0 48 -15 89 -34 65 -30 76 -32 76 -18 0 23 193 230 245 263 22 14 47 34 55 43 8 10 37 33 65 52 27 19 86 59 130 89 44 29 85 57 91 62 19 15 219 112 244 119 14 4 48 17 75 29 88 40 257 94 355 114 209 43 366 73 453 85 135 20 654 21 772 1z"></path>
<path d="M12443 8374 c-87 -12 -244 -42 -453 -85 -98 -20 -267 -74 -355 -114 -27 -12 -61 -25 -75 -29 -25 -7 -225 -104 -244 -119 -6 -5 -47 -33 -91 -62 -44 -30 -103 -70 -130 -89 -28 -19 -57 -42 -65 -52 -8 -9 -33 -29 -55 -43 -35 -23 -68 -56 -214 -213 -27 -30 -32 -41 -23 -50 14 -14 16 -48 4 -48 -5 0 -33 12 -63 26 -95 46 -161 74 -175 74 -7 0 -37 11 -66 24 -109 50 -175 75 -243 91 -38 10 -92 28 -118 41 -27 13 -56 24 -65 24 -9 0 -37 10 -62 21 -60 27 -170 58 -250 69 -36 5 -114 21 -175 36 -60 14 -144 33 -185 40 -41 8 -82 17 -90 20 -8 4 -62 10 -120 14 -58 4 -202 17 -320 28 -118 11 -259 24 -312 27 -53 4 -112 10 -132 15 -22 5 -36 4 -38 -2 -3 -7 -44 -7 -123 1 -147 15 -605 19 -895 8 -211 -8 -362 -25 -449 -53 -25 -8 -66 -14 -91 -14 -66 0 -205 -26 -267 -50 -29 -11 -92 -27 -140 -35 -180 -31 -681 -188 -754 -236 -13 -9 -67 -33 -119 -54 -52 -21 -102 -44 -110 -50 -8 -7 -38 -24 -66 -38 -27 -14 -56 -33 -63 -41 -8 -9 -20 -16 -27 -16 -8 0 -14 -4 -14 -10 0 -5 -19 -14 -42 -20 -24 -7 -59 -26 -78 -44 -19 -18 -53 -41 -75 -51 -48 -21 -65 -40 -65 -73 0 -21 -3 -23 -25 -18 -14 4 -45 9 -70 12 -24 4 -53 15 -64 25 -12 12 -47 22 -98 29 -92 12 -123 20 -223 56 -48 17 -100 28 -145 30 -109 4 -184 14 -265 35 -208 55 -928 54 -1435 -1 -229 -24 -234 -25 -465 -72 -205 -41 -459 -121 -635 -199 -127 -57 -327 -175 -378 -223 -20 -18 -56 -46 -81 -62 -26 -16 -49 -37 -52 -47 -3 -10 -18 -33 -33 -50 -39 -45 -71 -103 -92 -167 -22 -66 -25 -195 -5 -260 21 -68 76 -171 112 -210 93 -100 150 -150 171 -150 6 0 16 -6 20 -13 4 -8 27 -24 51 -37 23 -13 42 -27 42 -31 0 -4 10 -11 23 -15 12 -3 41 -19 65 -35 24 -16 47 -29 52 -29 16 0 100 -44 100 -52 0 -4 8 -8 19 -8 10 0 32 -7 47 -15 16 -8 39 -15 50 -15 12 0 27 -6 33 -14 7 -8 44 -22 83 -31 69 -15 117 -45 118 -72 0 -25 -84 -65 -194 -93 -118 -31 -222 -63 -271 -85 -16 -7 -61 -25 -100 -40 -38 -14 -91 -37 -117 -51 -25 -13 -63 -31 -85 -38 -103 -39 -190 -79 -226 -106 -23 -17 -46 -30 -51 -30 -6 0 -24 -11 -40 -25 -17 -14 -41 -28 -55 -32 -40 -9 -109 -61 -134 -98 -12 -18 -33 -40 -47 -48 -39 -24 -130 -113 -130 -128 0 -7 -15 -38 -34 -69 -48 -78 -72 -169 -59 -223 28 -110 52 -176 81 -221 18 -28 32 -54 32 -60 0 -5 33 -42 73 -82 39 -40 84 -85 99 -101 134 -137 213 -205 281 -238 41 -19 79 -35 86 -35 6 0 11 -8 11 -17 -1 -11 -29 -36 -71 -63 -39 -24 -88 -65 -110 -92 -22 -26 -49 -50 -60 -53 -10 -4 -26 -22 -34 -41 -8 -19 -20 -34 -28 -34 -21 0 -97 -58 -97 -75 0 -8 -9 -19 -20 -25 -11 -6 -20 -18 -20 -27 0 -18 -142 -163 -160 -163 -5 0 -12 -11 -16 -26 -8 -30 -89 -192 -108 -214 -40 -46 -79 -209 -75 -315 1 -44 1 -101 0 -127 -1 -26 5 -64 14 -84 8 -21 15 -66 15 -106 0 -66 4 -77 76 -226 47 -97 97 -182 129 -222 29 -36 61 -78 71 -95 10 -16 24 -34 31 -38 7 -4 13 -17 13 -27 0 -21 20 -43 176 -190 93 -88 119 -107 303 -210 28 -16 33 -20 96 -73 22 -18 78 -52 124 -75 46 -23 89 -46 95 -50 6 -5 45 -22 86 -37 41 -16 121 -50 177 -76 57 -26 128 -53 158 -58 30 -6 67 -17 82 -25 16 -8 57 -19 93 -26 36 -6 94 -20 130 -30 94 -28 307 -78 365 -86 28 -4 67 -13 89 -20 25 -9 86 -14 176 -14 105 0 147 -4 176 -16 35 -15 75 -16 354 -11 199 4 352 12 415 22 55 8 143 21 195 29 187 27 457 88 601 136 80 27 174 56 208 65 34 9 110 34 167 56 79 31 107 47 114 63 6 17 27 29 82 46 88 28 169 68 262 129 38 25 90 59 115 76 25 16 48 33 49 37 2 5 25 23 50 40 26 17 72 57 102 87 30 31 76 71 103 88 26 18 56 47 66 64 11 17 41 49 67 71 27 22 61 62 77 89 22 39 33 50 50 47 14 -2 23 -12 28 -33 3 -16 17 -52 31 -80 14 -27 28 -63 32 -80 4 -18 18 -36 34 -46 19 -11 35 -34 50 -75 16 -42 40 -76 82 -119 32 -33 87 -89 123 -125 35 -36 89 -81 121 -100 32 -19 73 -45 92 -57 19 -13 46 -26 60 -29 14 -4 48 -28 77 -54 57 -52 160 -112 252 -149 33 -13 101 -43 151 -68 50 -24 115 -51 143 -59 28 -8 74 -20 102 -28 27 -8 61 -22 74 -30 13 -9 33 -16 45 -16 11 0 29 -9 40 -20 13 -13 33 -20 59 -20 22 0 41 -5 43 -10 2 -6 44 -17 93 -25 50 -8 151 -30 225 -49 74 -19 178 -40 230 -46 52 -6 131 -20 175 -30 44 -10 112 -21 150 -25 39 -4 128 -16 199 -26 70 -10 163 -19 206 -19 42 0 146 -7 231 -16 126 -13 227 -14 549 -9 546 8 845 21 906 40 27 8 132 29 234 46 101 16 187 32 192 35 4 3 54 9 110 14 57 5 126 16 153 23 28 8 111 31 185 51 183 49 396 121 650 218 140 54 392 187 443 234 27 25 60 50 73 54 39 15 185 121 241 175 29 27 67 64 86 82 18 18 46 58 61 90 16 32 50 81 76 108 41 43 52 63 74 140 31 102 56 367 37 373 -6 2 -11 10 -11 17 0 10 61 14 298 18 297 6 442 18 667 55 66 11 178 28 248 37 71 9 143 23 161 30 18 8 64 19 102 25 83 14 314 88 441 141 50 22 94 39 98 39 21 0 209 91 245 118 19 15 61 44 92 64 31 20 64 48 73 62 9 14 32 30 51 36 24 8 36 19 40 38 12 55 16 62 55 92 31 26 39 38 39 65 0 23 10 46 35 75 33 39 35 47 35 110 0 62 -4 77 -44 152 -71 135 -89 164 -106 174 -57 32 -91 56 -158 109 -41 33 -83 64 -93 70 -32 17 -22 35 19 35 20 0 50 7 66 15 15 8 37 15 47 15 10 0 53 17 96 39 81 40 162 68 273 96 36 8 88 30 115 49 28 18 70 41 95 52 72 30 207 103 220 119 7 8 20 15 30 15 10 0 25 11 34 25 9 14 21 25 28 25 6 0 21 11 33 24 13 14 41 30 63 36 23 6 53 24 69 42 15 17 82 87 148 155 67 69 136 151 157 186 61 105 78 137 78 153 0 8 12 38 26 67 l27 52 -12 210 c-11 182 -15 213 -32 235 -11 14 -27 38 -37 54 -50 86 -102 154 -133 174 -19 13 -41 36 -50 52 -18 33 -75 100 -85 100 -3 0 -27 17 -53 38 -97 81 -358 252 -383 252 -10 0 -65 23 -122 50 -57 28 -109 50 -116 50 -6 0 -24 7 -38 15 -70 38 -184 79 -266 96 -50 10 -125 30 -166 44 -41 14 -106 33 -145 41 -38 8 -102 26 -142 39 -39 14 -83 25 -98 25 -25 0 -26 2 -19 38 4 20 11 46 16 56 6 10 14 53 18 95 4 42 15 101 24 131 9 30 19 93 22 140 6 75 3 96 -19 170 -15 47 -29 99 -33 115 -12 51 -74 208 -102 255 -14 25 -47 72 -73 105 -25 33 -53 74 -62 90 -26 52 -217 255 -239 255 -6 0 -16 6 -22 13 -14 18 -171 147 -211 174 -16 11 -93 47 -170 78 -77 32 -159 71 -181 86 -68 46 -188 91 -369 139 -60 16 -152 41 -204 55 -51 14 -141 29 -200 35 -58 6 -146 17 -196 25 -117 19 -579 19 -712 -1z" style="fill:#b3b3b3"></path>
</g>
</svg>
</svg>
But when I tried to move the image using transform and translate, It moved but it is not shown because of my viewbox
Is there any way so that i can move my path so it can be displayed?
Thanks
> https://jsfiddle.net/namkhoai16/cyn502hz/1/
As I've commented. This is what you can do:
1.transform .may in a symbol and remove the width and the height attributes.
2.give may an id. For example id="may" you will use the id to reference the symbol
3.use the symbol something like this: <use xlink:href="#may" height="300" width="300" />
Now you can apply the transformation to the use element.
<use xlink:href="#may" height="300" width="300" transform="translate(300,100)" />
<svg class="map" height="50000" width="50000">
<symbol id="may" preserveAspectRatio="none" viewBox="0 0 17275 8599" >
<g>
<path d="M12443 8374 c-87 -12 -244 -42 -453 -85 -98 -20 -267 -74 -355 -114 -27 -12 -61 -25 -75 -29 -25 -7 -225 -104 -244 -119 -6 -5 -47 -33 -91 -62 -44 -30 -103 -70 -130 -89 -28 -19 -57 -42 -65 -52 -8 -9 -33 -29 -55 -43 -35 -23 -68 -56 -214 -213 -27 -30 -32 -41 -23 -50 14 -14 16 -48 4 -48 -5 0 -33 12 -63 26 -95 46 -161 74 -175 74 -7 0 -37 11 -66 24 -109 50 -175 75 -243 91 -38 10 -92 28 -118 41 -27 13 -56 24 -65 24 -9 0 -37 10 -62 21 -60 27 -170 58 -250 69 -36 5 -114 21 -175 36 -60 14 -144 33 -185 40 -41 8 -82 17 -90 20 -8 4 -62 10 -120 14 -58 4 -202 17 -320 28 -118 11 -259 24 -312 27 -53 4 -112 10 -132 15 -22 5 -36 4 -38 -2 -3 -7 -44 -7 -123 1 -147 15 -605 19 -895 8 -211 -8 -362 -25 -449 -53 -25 -8 -66 -14 -91 -14 -66 0 -205 -26 -267 -50 -29 -11 -92 -27 -140 -35 -180 -31 -681 -188 -754 -236 -13 -9 -67 -33 -119 -54 -52 -21 -102 -44 -110 -50 -8 -7 -38 -24 -66 -38 -27 -14 -56 -33 -63 -41 -8 -9 -20 -16 -27 -16 -8 0 -14 -4 -14 -10 0 -5 -19 -14 -42 -20 -24 -7 -59 -26 -78 -44 -19 -18 -53 -41 -75 -51 -48 -21 -65 -40 -65 -73 0 -21 -3 -23 -25 -18 -14 4 -45 9 -70 12 -24 4 -53 15 -64 25 -12 12 -47 22 -98 29 -92 12 -123 20 -223 56 -48 17 -100 28 -145 30 -109 4 -184 14 -265 35 -208 55 -928 54 -1435 -1 -229 -24 -234 -25 -465 -72 -205 -41 -459 -121 -635 -199 -127 -57 -327 -175 -378 -223 -20 -18 -56 -46 -81 -62 -26 -16 -49 -37 -52 -47 -3 -10 -18 -33 -33 -50 -39 -45 -71 -103 -92 -167 -22 -66 -25 -195 -5 -260 21 -68 76 -171 112 -210 93 -100 150 -150 171 -150 6 0 16 -6 20 -13 4 -8 27 -24 51 -37 23 -13 42 -27 42 -31 0 -4 10 -11 23 -15 12 -3 41 -19 65 -35 24 -16 47 -29 52 -29 16 0 100 -44 100 -52 0 -4 8 -8 19 -8 10 0 32 -7 47 -15 16 -8 39 -15 50 -15 12 0 27 -6 33 -14 7 -8 44 -22 83 -31 69 -15 117 -45 118 -72 0 -25 -84 -65 -194 -93 -118 -31 -222 -63 -271 -85 -16 -7 -61 -25 -100 -40 -38 -14 -91 -37 -117 -51 -25 -13 -63 -31 -85 -38 -103 -39 -190 -79 -226 -106 -23 -17 -46 -30 -51 -30 -6 0 -24 -11 -40 -25 -17 -14 -41 -28 -55 -32 -40 -9 -109 -61 -134 -98 -12 -18 -33 -40 -47 -48 -39 -24 -130 -113 -130 -128 0 -7 -15 -38 -34 -69 -48 -78 -72 -169 -59 -223 28 -110 52 -176 81 -221 18 -28 32 -54 32 -60 0 -5 33 -42 73 -82 39 -40 84 -85 99 -101 134 -137 213 -205 281 -238 41 -19 79 -35 86 -35 6 0 11 -8 11 -17 -1 -11 -29 -36 -71 -63 -39 -24 -88 -65 -110 -92 -22 -26 -49 -50 -60 -53 -10 -4 -26 -22 -34 -41 -8 -19 -20 -34 -28 -34 -21 0 -97 -58 -97 -75 0 -8 -9 -19 -20 -25 -11 -6 -20 -18 -20 -27 0 -18 -142 -163 -160 -163 -5 0 -12 -11 -16 -26 -8 -30 -89 -192 -108 -214 -40 -46 -79 -209 -75 -315 1 -44 1 -101 0 -127 -1 -26 5 -64 14 -84 8 -21 15 -66 15 -106 0 -66 4 -77 76 -226 47 -97 97 -182 129 -222 29 -36 61 -78 71 -95 10 -16 24 -34 31 -38 7 -4 13 -17 13 -27 0 -21 20 -43 176 -190 93 -88 119 -107 303 -210 28 -16 33 -20 96 -73 22 -18 78 -52 124 -75 46 -23 89 -46 95 -50 6 -5 45 -22 86 -37 41 -16 121 -50 177 -76 57 -26 128 -53 158 -58 30 -6 67 -17 82 -25 16 -8 57 -19 93 -26 36 -6 94 -20 130 -30 94 -28 307 -78 365 -86 28 -4 67 -13 89 -20 25 -9 86 -14 176 -14 105 0 147 -4 176 -16 35 -15 75 -16 354 -11 199 4 352 12 415 22 55 8 143 21 195 29 187 27 457 88 601 136 80 27 174 56 208 65 34 9 110 34 167 56 79 31 107 47 114 63 6 17 27 29 82 46 88 28 169 68 262 129 38 25 90 59 115 76 25 16 48 33 49 37 2 5 25 23 50 40 26 17 72 57 102 87 30 31 76 71 103 88 26 18 56 47 66 64 11 17 41 49 67 71 27 22 61 62 77 89 22 39 33 50 50 47 14 -2 23 -12 28 -33 3 -16 17 -52 31 -80 14 -27 28 -63 32 -80 4 -18 18 -36 34 -46 19 -11 35 -34 50 -75 16 -42 40 -76 82 -119 32 -33 87 -89 123 -125 35 -36 89 -81 121 -100 32 -19 73 -45 92 -57 19 -13 46 -26 60 -29 14 -4 48 -28 77 -54 57 -52 160 -112 252 -149 33 -13 101 -43 151 -68 50 -24 115 -51 143 -59 28 -8 74 -20 102 -28 27 -8 61 -22 74 -30 13 -9 33 -16 45 -16 11 0 29 -9 40 -20 13 -13 33 -20 59 -20 22 0 41 -5 43 -10 2 -6 44 -17 93 -25 50 -8 151 -30 225 -49 74 -19 178 -40 230 -46 52 -6 131 -20 175 -30 44 -10 112 -21 150 -25 39 -4 128 -16 199 -26 70 -10 163 -19 206 -19 42 0 146 -7 231 -16 126 -13 227 -14 549 -9 546 8 845 21 906 40 27 8 132 29 234 46 101 16 187 32 192 35 4 3 54 9 110 14 57 5 126 16 153 23 28 8 111 31 185 51 183 49 396 121 650 218 140 54 392 187 443 234 27 25 60 50 73 54 39 15 185 121 241 175 29 27 67 64 86 82 18 18 46 58 61 90 16 32 50 81 76 108 41 43 52 63 74 140 31 102 56 367 37 373 -6 2 -11 10 -11 17 0 10 61 14 298 18 297 6 442 18 667 55 66 11 178 28 248 37 71 9 143 23 161 30 18 8 64 19 102 25 83 14 314 88 441 141 50 22 94 39 98 39 21 0 209 91 245 118 19 15 61 44 92 64 31 20 64 48 73 62 9 14 32 30 51 36 24 8 36 19 40 38 12 55 16 62 55 92 31 26 39 38 39 65 0 23 10 46 35 75 33 39 35 47 35 110 0 62 -4 77 -44 152 -71 135 -89 164 -106 174 -57 32 -91 56 -158 109 -41 33 -83 64 -93 70 -32 17 -22 35 19 35 20 0 50 7 66 15 15 8 37 15 47 15 10 0 53 17 96 39 81 40 162 68 273 96 36 8 88 30 115 49 28 18 70 41 95 52 72 30 207 103 220 119 7 8 20 15 30 15 10 0 25 11 34 25 9 14 21 25 28 25 6 0 21 11 33 24 13 14 41 30 63 36 23 6 53 24 69 42 15 17 82 87 148 155 67 69 136 151 157 186 61 105 78 137 78 153 0 8 12 38 26 67 l27 52 -12 210 c-11 182 -15 213 -32 235 -11 14 -27 38 -37 54 -50 86 -102 154 -133 174 -19 13 -41 36 -50 52 -18 33 -75 100 -85 100 -3 0 -27 17 -53 38 -97 81 -358 252 -383 252 -10 0 -65 23 -122 50 -57 28 -109 50 -116 50 -6 0 -24 7 -38 15 -70 38 -184 79 -266 96 -50 10 -125 30 -166 44 -41 14 -106 33 -145 41 -38 8 -102 26 -142 39 -39 14 -83 25 -98 25 -25 0 -26 2 -19 38 4 20 11 46 16 56 6 10 14 53 18 95 4 42 15 101 24 131 9 30 19 93 22 140 6 75 3 96 -19 170 -15 47 -29 99 -33 115 -12 51 -74 208 -102 255 -14 25 -47 72 -73 105 -25 33 -53 74 -62 90 -26 52 -217 255 -239 255 -6 0 -16 6 -22 13 -14 18 -171 147 -211 174 -16 11 -93 47 -170 78 -77 32 -159 71 -181 86 -68 46 -188 91 -369 139 -60 16 -152 41 -204 55 -51 14 -141 29 -200 35 -58 6 -146 17 -196 25 -117 19 -579 19 -712 -1z"></path>
</g>
</symbol>
<use xlink:href="#may" height="300" width="300" transform="translate(300,100)" />
</svg>
Observation: I've removed one of the 2 paths to simplify a little the code.
Tel | Handy
_______________________|_____________________________
Sprache: Deutsch Tel.: +41 31 761 14 33
Sprache: Deutsch Tel.: 079 658 71 71
Sprache: Deutsch Handy: 076 517 20 94
Sprache: Deutsch Tel.: 079 296 00 65
Tel.: 061 981 3804 Handy: 079 415 83 57
Sprache: Deutsch Tel.: 041 497 37 94
Sprache: Deutsch Tel.: 079 735 43 71
Sprache: Deutsch Tel.: 041 390 07 06
Sprache: Deutsch Tel.: 079 703 36 26
Handy: 078 738 7222 franziskafroschmayer#me.com
Sprache: Deutsch Tel.: 044 776 88 60
Sprache: Deutsch Tel.: 044 740 82 19
Sprache: Deutsch Tel.: 076 335 77 51
Tel.: 062 721 0677 aegerter_b#bluewin.ch
Sprache: Deutsch Handy: 079 483 17 65
I have the above two columns in a excel sheet. I would like to copy the all the Column values(not entire row) which has word "Handy" in Tel column and paste it in a column handy
I have no clue how to do that. Either in MS excel or google spreadsheet. Hope I am clear.
Autofilter the data in the "tel" column using the Text Filters -> "contains" option; then copy all elements that are still visible in "Tel" and copy them to "Handy". In the process you will overwrite whatever was in "handy" - but your question didn't suggest that that was a problem.
Suggest that you do this on a copy of the spreadsheet, not the original... just to make sure you don't mess it up. But this should work.