axis

Adjusting Axis in Matplotlib

浪子不回头ぞ 提交于 2020-01-06 04:27:09
问题 When creating my graph using Matplotlib, I have coded it to automatically size the axis as follows: plt.axis([(int(yearofreleaselist[oldestfilm])-1), (int(yearofreleaselist[0]))+1, 0, (max(profits))+50000000]) However, dealing with large figures, the profits only displays a single digit with various shorthand references, as seen on this example graph: The year of release also doesn't plot correctly, but some results are displayed properly, as seen here: I'm wondering how to fix this so the

Python bokeh show only every second categorical ticker

微笑、不失礼 提交于 2020-01-06 03:51:06
问题 How can I set for a CategoricalAxis not to show every ticker but just every second or third one? Let say I have 20 categorics on x-axis . I tried this but it does not work: ticker = CategoricalTicker(desired_num_ticks=10) xaxis = CategoricalAxis(ticker=ticker) my_fig.add_layout(xaxis, 'above') It shows all my tickers :( EDIT: It would be great to show only every second label as well... Thank you! 来源: https://stackoverflow.com/questions/34949298/python-bokeh-show-only-every-second-categorical

tools.jar missing - but only on the very first call (Tomcat 8/Java 8/ Axis)

[亡魂溺海] 提交于 2020-01-06 02:26:29
问题 Now that I upgraded my webapp to Java 8, I'm running into strange classloading problem with an axis webservice that is running in Tomcat 8. The very first call to the webservice after installing the webapp will cause a RuntimeException and a "No compiler found in your classpath! (you may need to add 'tools.jar')" fault. All following calls to that webservice work correctly (apparently tools.jar is there after all?). The behaviour is reproducable by deleting the exploded webapp folder in the

GNUPlot Draw label on x2y2 axes

旧街凉风 提交于 2020-01-05 17:30:12
问题 I want to place a label on a plot which uses autoscale. To keep the label at the same position i want to use alternative axis which don't use autoscale to get an absolute location. How can I choose the uses axis of a "set label" statement? set y2range [0:10] set x2range [0:100] set label "FooBar" at 10, 5 Line 3: something is missing here. "axes x2y2" wont work (used in plot label functions) Thanks for helping me out here :-) 回答1: There are different coordinate systems which you can use to

ggplot2 differences in scale_x_date and scale_x_datetime

不打扰是莪最后的温柔 提交于 2020-01-05 04:00:12
问题 I am trying to produce 2 graphs from different data sets in ggplot. I want the graphs to have the same x axis breaks and labels. One of the graphs has a scale_x_date axis and the other a scale_x_datetime axis. Despite giving these functions the same arguments, the resulting axis are different. I cant figure out how to make them the same. The 2 datasets "soil_N_summary.csv" and "weather_data.csv" can be downloaded here. I have used the following code to produce the graphs shown below: library

np.expand_dims的使用

我怕爱的太早我们不能终老 提交于 2020-01-04 21:14:12
关于np.expand_dims的使用,网上好多举了一些实例,自己在平时也常见,但总是有点迷糊,我知道它的作用是扩展一个张量的维度,但结果是如何变化得到的,想来想去不是太明了,所以去函数源码看了一下,算是明白了,np.expand_dims的源码如下: def expand_dims(a, axis): """ Expand the shape of an array. Insert a new axis that will appear at the `axis` position in the expanded array shape. .. note:: Previous to NumPy 1.13.0, neither ``axis < -a.ndim - 1`` nor ``axis > a.ndim`` raised errors or put the new axis where documented. Those axis values are now deprecated and will raise an AxisError in the future. Parameters ---------- a : array_like Input array. axis : int Position in the expanded axes where the new

Plot of minute tick data with correct x-axis formatting?

元气小坏坏 提交于 2020-01-04 18:20:07
问题 I want to plot tick data on a minute-basis. My dataframe looks like the following: > head(df) No Date Time Close Volume Weekday 1 3361 03.12.2012 08:00:00.000 7.435 27000000 Montag 2 3362 03.12.2012 08:01:00.000 7.428 47000000 Montag 3 3363 03.12.2012 08:02:00.000 7.428 41000000 Montag 4 3364 03.12.2012 08:03:00.000 7.429 39000000 Montag 5 3365 03.12.2012 08:04:00.000 7.426 44000000 Montag 6 3366 03.12.2012 08:05:00.000 7.423 49000000 Montag > Now I want to plot the first 241 entries, with

Weird certificate error when trying to generate web service client from secure site

我们两清 提交于 2020-01-04 14:35:12
问题 I get a weird error when trying to use AXIS1.4 Wsdl2Java tool to generate client code for the web service that is installed on the secure IIS site. When I run the tool I get the following SSL exception: javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: No name matching XXXXXXX.net found at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:174) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1 591) at com.sun.net.ssl.internal.ssl

Python, Bokeh: How to change range of datetime axis

感情迁移 提交于 2020-01-03 19:41:11
问题 I would like to set the range of a datetime axis using a button. However, the command f.x_range = Range1d(start=start_date, end=end_date) doesn't work. When clicking the button nothing happens. I don't get any errors, neither in the terminal windows running the Bokeh server, nor in the console output of my Chrome web browser. You find the entire code below. I'm grateful for any advice. Thanks, Julian # Import libraries from bokeh.io import curdoc from bokeh.models import ColumnDataSource,

Python, Bokeh: How to change range of datetime axis

独自空忆成欢 提交于 2020-01-03 19:41:04
问题 I would like to set the range of a datetime axis using a button. However, the command f.x_range = Range1d(start=start_date, end=end_date) doesn't work. When clicking the button nothing happens. I don't get any errors, neither in the terminal windows running the Bokeh server, nor in the console output of my Chrome web browser. You find the entire code below. I'm grateful for any advice. Thanks, Julian # Import libraries from bokeh.io import curdoc from bokeh.models import ColumnDataSource,